I need help plz it’s python

I Need Help Plz Its Python

Answers

Answer 1

Answer:

The output of the first question would be 9. And the answer the second question is 10.


Related Questions

so i am on a Chromebook with headphones , and I am wondering if you can make it that a tab only play sound on one side of the headphones and other tabs to the other side of the headphones

Answers

No you cannot do that with a single pair of headphones. If you had an dual aux split... you could plug in two pairs of headphones... even if you had two bluetooth pairs I don't think it'd be possible... What do you need to do that for? Maybe I can help find an alternative solution

4.9 Code Practice: Question 4 Edhisive

Write a program that asks the user to enter ten temperatures and then finds the sum. The input temperatures should allow for decimal values.

Sample Run
Enter Temperature: 27.6
Enter Temperature: 29.5
Enter Temperature: 35
Enter Temperature: 45.5
Enter Temperature: 54
Enter Temperature: 64.4
Enter Temperature: 69
Enter Temperature: 68
Enter Temperature: 61.3
Enter Temperature: 50
Sum = 504.3

Answers

i = 0

total = 0

while i < 10:

   temp = float(input("Enter Temperature: "))

   total += temp

   i += 1

print("Sum: {}".format(total))

I wrote my code in python 3.8. I hope this helps!

The program accepts 10 temperature inputs from the user, and takes the sum of the inputs gives before displaying the total sum of the temperature. The program is written in python 3 ;

temp_count = 0

#initialize the number of temperature inputs given by the user and assign to temp_count variable

sum = 0

#initialize the sum of the temperature inputs given

while(temp_count < 10):

#loop allows 10 inputs from the user

values = eval(input('Enter temperature : '))

#prompts user to input temperature values

sum+= values

#adds the inputted values to sum

temp_count+=1

#increases count of input by 1

print('sum of temperature : ', sum)

#displays the total sum

Learn more :https://brainly.com/question/18253379

def list_length(shrinking_list): ''' A recursive way to count the number of items in a list. ''' if shrinking_list

Answers

Answer:

Written in Python:

def list_length(shrinking_list):

    if not shrinking_list:

         return 0

    else:

         return list_length(shrinking_list[1:]) + len(shrinking_list[0])

Explanation:

This defines the list

def list_length(shrinking_list):

This checks if list is empty, if yes it returns 0

    if not shrinking_list:

         return 0

If list is not empty,

    else:

This calculates the length of the list, recursively

         return list_length(shrinking_list[1:]) + len(shrinking_list[0])

To call the function from the main, use:

print(list_length(listname))

What missing condition will give you the output shown? numB = 2 while _____: numB = numB + 3 print(numB) Output: 14 numB 10 numB > 12 numB < 10

Answers

Answer:

A. numB < 12

Explanation:

Correct answer edge 2020

Answer: A. numB < 12

Explanation: got it right edgen

Jamal wants to write a program that will find the 10 most common words in Romeo and Juliet. Which of the following constructs will be most helpful?

A. counter module

B. while loop

C. for loop

D. mean module

Answers

Answer:

The answer to this question is given below in the explanation section.

Explanation:

The correct answer to this question is A: counter module.

Counter module in python or Python counter is a container that holds the count of each of the elements present in the container. It is a sub-class available in the dictionary class. Jamal can use this module in Python to write a program that will find the 10 most common words in Romeo and Juliet.

Other options are not correct because:

While loop: while loop only iterates its body until a specific condition is met. For loop is used to iterate to a pre-specified condition and iterate until the condition is reached. While the mean module of Python is used to calculate mean and average.

Declare a class named PatientData that contains two attributes named height_inches and weight_pounds.

Answers

Answer:

class PatientData:

   def __init__(self, height_inches, weight_pounds):

      self.height_inches = height_inches

      self.weight_pounds = weight_pounds

a_patient = PatientData(75, 125)

print("Patient's height:", a_patient.height_inches)

print("Patient's weight:", a_patient.weight_pounds)

Explanation:

Create a class named PatientData

Inside the class, create a constructor (def __init__), that takes two parameters, height_inches and weight_pounds. This is used to initialize the PatientData objects. Inside the constructor, set the height_inches and weight_pounds

Create PatientData object named a_patient. Note that in order to create an object, you need to specify the height_inches and weight_pounds

Then, you may access these values by typing the object name, ".", and variable name. For example, to access the height_inches, you should write the following:

→ a_patient.height_inches

Then, print the height and weight of the patient

Functional languages like LISP are not composed of statements, but instead are a nested set of functions.
a) True
b) False

True
False

Answers

Answer:

True

In a purely functional language everything is a function and functions are based of other functions.

Answer:

true

Explanation:

What causes them to catch your attention in advertisements?

Answers

Answer:

advertisement should be nice and attractive to get attention of people

What stage is the most inner part of the web architecture where data such as, customer names, addresses, account numbers, and credit card info, is stored

Answers

Answer:

Database

Explanation:

A website or web application is a page or a collection of pages addressing the same information on the internet. Web pages and the whole web application is made by a web developer using tools like HTML, CSS, Javascript, Flask, react.js, etc.

All websites or applications require a fast, flexible but secure source of storage to hold information. This storage is called a database. Examples of databases are relational and non-relational databases.

Write a program that contains three methods:

Method max (int x, int y, int z) returns the maximum value of three integer values.
Method min (int X, int y, int z) returns the minimum value of three integer values.
Method average (int x, int y, int z) returns the average of three integer values.

Answers

Answer:

#include <stdio.h>//defining header file

int max (int x, int y, int z) //defining a method max that hold three parameters

{

   if(x>=y && x>=z)//defining if block that checks x is greater then y and x is greater then z

   {

       return x;//return the value x

   }

   else if(y>z)//defining else if block it check y is greater then z

   {

       return y;//return the value y

   }

   else//else block

   {

       return z;//return the value z

   }

}

int min (int x, int y, int z) //defining a method max that holds three parameters

{

if(x<=y && x<=z) //defining if block that check x value is less then equal to y and less then equal to z

{

return x;//return the value of x

}

if(y<=x && y<=z) //defining if block that check y value is less then equal to x and less then equal to z

{

return y;//return the value of y

}

if(z<=x && z<=x)//defining if block that check z value is less then equal to x  

{

return z;//return the value of z

}

return x;//return the value of z  

}

int average (int x, int y, int z) //defining average method that take three parameters

{

int avg= (x+y+z)/3;//defining integer variable avg that calculate the average

return avg;//return avg value

}

int main()//defining main method

{

   int x,y,z;//defining integer variable

   printf("Enter first value: ");//print message

   scanf("%d",&x);//input value from the user end

   printf("Enter Second value: ");//print message

   scanf("%d",&y);//input value from the user end

   printf("Enter third value: ");//print message

   scanf("%d",&z);//input value from the user end

   printf("The maximum value is: %d\n", max(x,y,z));//calling the method max

   printf("The minimum value is: %d\n", min(x,y,z));//calling the method min

   printf("The average value is: %d\n", average(x,y,z));//calling the method average

   return 0;

}

Output:

Enter first value: 45

Enter Second value: 35

Enter third value: 10

The maximum value is: 45

The minimum value is: 10

The average value is: 30

Explanation:

In the above-given code, three methods "max, min, and average" is declared that holds three integer variable "x,y, and z" as a parameter and all the method work as their respective name.

In the max method, it uses a conditional statement to find the highest number among them.In the min method, it also uses the conditional statement to find the minimum value from them.In the average method, it defined an integer variable "avg" that holds the average value of the given parameter variable.In the main method, three variable is defined that inputs the value from the user end and passes to the method and print its value.      

A Protocol for networked information​

Answers

Answer:

Internet Protocol (IP), which uses a set of rules to send and receive messages at the Internet address level; and. additional network protocols that include the Hypertext Transfer Protocol (HTTP) and File Transfer Protocol (FTP), each of which has defined sets of rules to exchange and display information.

Explanation:

could i plz have brainliest so close to next rank

Write a program with 2 separate functions which compute the GCD (Greatest Common Denominator) and the LCM (Lowest Common Multiple) of two input integers.

Answers

Answer:

The program written in Python is as follows

def GCD(num1, num2):

    small = num1

    if num1 > num2:

         small = num2

    for i in range(1, small+1):

         if((num1 % i == 0) and (num2 % i == 0)):

              gcd = i

    print("The GCD is "+ str(gcd))

def LCM(num1,num2):

    big = num2  

    if num1 > num2:

         big = num1

    while(True):

         if((big % num1 == 0) and (big % num2 == 0)):

              lcm = big

              break

         big = big+1

     print("The LCM is "+ str(lcm))

 print("Enter two numbers: ")

num1 = int(input(": "))

num2 = int(input(": "))

GCD(num1, num2)

LCM(num1, num2)

Explanation:

This line defines the GCD function

def GCD(num1, num2):

This line initializes variable small to num1

    small = num1

This line checks if num2 is less than num1, if yes: num2 is assigned to variable small

    if num1 > num2:

         small = num2

The following iteration determines the GCD of num1 and num2

    for i in range(1, small+1):

         if((num1 % i == 0) and (num2 % i == 0)):

              gcd = i

This line prints the GCD

    print("The GCD is "+ str(gcd))

   

This line defines the LCM function

def LCM(num1,num2):

This line initializes variable big to num2

    big = num2  

This line checks if num1 is greater than num2, if yes: num1 is assigned to variable big

    if num1 > num2:

         big = num1

The following iteration continues while the LCM has not been gotten.

    while(True):

This if statement determines the LCM using modulo operator

         if((big % num1 == 0) and (big % num2 == 0)):

              lcm = big

              break

         big = big+1

This line prints the LCM of the two numbers

     print("The LCM is "+ str(lcm))

The main starts here

This line prompts user for two numbers

print("Enter two numbers: ")

The next two lines get user inputs

num1 = int(input(": "))

num2 = int(input(": "))

This calls the GCD function

GCD(num1, num2)

This calls the LCM function

LCM(num1, num2)

See attachment for more structured program

Which of the following server types is in the form of a single circuit board?
a. blade
b. tower
O c. rack
O d. dedicated
o

Answers

Answer:

A. Blade

Explanation:

Server Blade means a complete computer system on a single board which includes one or more CPUs, memory, operating system, network connections, and typically includes access to hard drives or other mass storage devices. A Server Blade is designed to be inserted into a space-saving rack, and each rack may contain a number of Server Blades served by one or more power supplies.

If this is multiple choice, a dedicated server can be too.

write aemail to brother for laptop for vitrual classes​

Answers

Answer:

If I were to ask my brother for a laptop, I would go:

Hey, can I have your laptop? I need it for online classes.

Sincerely, [my name]

Dear brother, I really need a lab top for my online classes (explain why you don’t have one) i would really appreciate it :)

Sincerely,
Your bro/ Sis

Computer Architecture
1. Define what a "word" is in computer architecture:
A. The size (number of bits) of the address
B. The total number of bits of an instruction (e.g. 16 bits)
C. Word and width are synonymous.
D. A word is the contents of a memory register.
2. What is the difference between a register’s width and a register’s address? (choose all that apply - there may be more than one correct answer)
A. They are both the same!
B. Address is the same for all registers, width is unique for each register.
C. Width is the amount of data a single register holds, address is the location of the register within a larger chip.
D. The address bits of a register is a logarithm of its width.
3. Which of the following is NOT implemented by the Program Counter?
A. Set the counter to 0.
B. Increase the counter by 1.
C. Decrease the counter by 1.
D. Set the counter to any input value.
4. What is the relationship between the size of the address (number of bits) and the word size for memory registers?
A. address bits = 2^(word size)
B. address bits = word size ^ 2
C. address bits = word size
D. address bits = log2(word size)
E. address bits = (word size) / 2

Answers

Answer:

BADDA

Explanation:

BIIING

Write a function named findmax()that finds and displays the maximum values in a two dimensional array of integers. The array should be declared as a 10 row by 15 column array of integers in main()and populated with random numbers between 0 and 100.

Answers

Answer:

import java.util.*;

public class Main

{

public static void main(String[] args) {

    Random r = new Random();

    int[][] numbers = new int[10][15];

   

    for (int i=0; i<10; i++){

        for (int j=0; j<15; j++){

            numbers[i][j] = new Random().nextInt(101);

        }

    }

   

    for (int i=0; i<10; i++){

        for (int j=0; j<15; j++){

            System.out.print(numbers[i][j] + " ");

        }

        System.out.println();

    }

   

    findmax(numbers);

}

public static void findmax(int[][] numbers){

    int max = numbers[0][0];

   

    for (int i=0; i<10; i++){

        for (int j=0; j<15; j++){

            if(numbers[i][j] > max)

                max = numbers[i][j];

        }

    }

    System.out.println("The max is " + max);

}

}

Explanation:

*The code is in Java.

Create a function called findmax() that takes one parameter, numbers array

Inside the function:

Initialize the max as first number in the array

Create a nested for loop that iterates through the array. Inside the second for loop, check if a number is greater than the max. If it is set it as the new max

When the loop is done, print the max

Inside the main:

Initialize a 2D array called numbers

Create a nested for loop that sets the random numbers to the numbers array. Note that to generate random integers, nextInt() function in the Random class is used

Create another nested for loop that displays the content of the numbers array

Call the findmax() function passing the numbers array as a parameter

Online
Activities
Media Literacy
Information
Literacy
Technology
Literacy
Content
(appropriateness,
tone, recipient,
others)
tools (mobile,
computers,
others)
Sending an as platform (text;
electronic
email; messenger,
message
video
message;
voice message:
others)
Getting the latest traditional
(newspaper, tv,
radio, others)
digital (websites,
social media,
others)
news
Content
(appropriateness,
reliability, accuracy,
tone, audience,
others) giving
feedback (reactions,
comments, rate,
others)
knowing how to
use mass
media platforms
(tv, radio, others)
where to access
digital content
navigational skills
Entertainment
Business
Education
sources​

Answers

Answer:

i can't understand what u want to say

give the one simple program using c++programming language​

Answers

Answer:

the ejedjrjr eenekrr

eueeue

Explanation:

u4rururirw

The designer of an agent traveled to a beach for a holiday. He took the agent to the beach. He wanted the agent to capture the sunrise and the high tide. What kind of knowledge representation will the agent use in this new environment?

A.
picture
B.
number
C.
graph
D.
meta

Answers

The answer is C. Which is graph

Answer:

Picture

Explanation:

what is a technology?​

Answers

Answer:

The definition of technology is science or knowledge put into practical use to solve problems or invent useful tools

                                                    OR

Technology is the sum of techniques, skills, methods, and processes used in the production of goods or services or in the accomplishment of objectives, such as scientific investigation

Dance dance1 = new Dance("Tango","Hernandos Hideaway");
Dance dance2 = new Dance("Swing","Hound Dog");
System.out.println(dance1.toString());

System.out.println(dance2.toString());

class Dance
{
private String name;
private String song;

public Dance(String name, String s)
{
this.name = name;
song = s;
}

public String toString()
{
return name + " " + song;
}
}
What is printed when the program is executed?


a
null null

null null

b
Hernandos Hideaway null

Hound Dog null

c
null null

Swing Hound Dog

d
Tango Hernados Hideaway

Swing Hound Dog

e
null Hernandos Hideaway

null Hound Dog

Answers

Answer:

The output of the program is (d)

Tango Hernados Hideaway

Swing Hound Dog

Explanation:

Analyzing the given code segment

In class Dance,

A method named dance was defined with an instance of two string variables/values

which are name and song

public Dance(String name, String s)

In the main of the program,

The first line creates an instance of Dance as dance1

dance1 is initialized with the following string values: "Tango","Hernandos Hideaway"

- The first string value "Tango" will be passed into the name variable of the Dance method

- The second string value "Hernandos Hideaway" will be passed into the song variable of the Dance method

Next, another instance of Dance is initialized as dance2

dance2 is initialized with the following string values: "Swing","Hound Dog"

- The first string value "Swing" will be passed into the name variable of the Dance method

- The second string value "Hound Dog" will be passed into the song variable of the Dance method

On line 3 of the main: System.out.println(dance1.toString());

The values of dance1, which are "Tango","Hernandos Hideaway" are printed

On line 4 of the main: System.out.println(dance2.toString());

The values of dance1, which are "Swing","Hound Dog" are printed

Hence, option d answers the question

Explain what resampling is? in ict (igcse)​

Answers

Answer:

Resampling

Explanation:

This means resizing an image by reducing or increasing the image's number of pixels.

HOPE THIS HELPED

True/False: A datasum can be generated for any width of data. For example, we can create an 8, 16, or 32 bit datasum for 8, 16, or 32 bit data elements respectively.

Answers

Answer:

true

Explanation:

How can we use variables to store information in our programs?

Answers

Computer programs use variables to store information.
...
To make a simple program that displays your name, you could program the computer to:
Ask for your name.
Store that answer as a variable called 'YourName'.
Display “Hello” and the string stored in the variable called 'YourName'

patintero
a.tag game
b.target game​

Answers

Patintero, also known as harangang-taga or tubigan, is a traditional Filipino children's game. Along with tumbang preso, it is one of the most popular outdoor games played by children in the Philippines.

In other words tag game

Hope this helps

An uniterruptible power supply

Answers

Answer:

An uninterruptible power supply  is an electrical apparatus that provides emergency power to a load when the input power source or mains power fails.

Explanation:

Your welcome :) PLZ mark brainliest

help me pls difhdifhedioheiofhoidhvoidheiofhioefhioe

Answers

Answer:

thanks for the free points

The Operating System provides utility software designed to perform specific tasks. What task(s) does it perform? Select all that apply.
A. Establishing an Internet connection
B. Coordinating tasks between programs
C. Configuring peripheral devices
D. Monitoring security

Answers

Answer:

All of the above.

Explanation:

An operating system is a system software pre-installed on a computing device to manage or control software application, computer hardware and user processes.

This ultimately implies that, an operating system acts as an interface or intermediary between the computer end user and the hardware portion of the computer system (computer hardware) in the processing and execution of instructions.

Some examples of an operating system on computers are QNX, Linux, OpenVMS, MacOS, Microsoft windows, IBM, Solaris, VM etc.

Hence, the operating system (OS) provides utility software designed to perform specific tasks. Some of the tasks it performs are;

A. Establishing an Internet connection.

B. Coordinating tasks between programs.

C. Configuring peripheral devices.

D. Monitoring security.

my game is telling me to "Press any key." Where is the "any" key?????

Answers

Answer:

It's mean press any key which you want to press.

There is no key called "any" key.

All early programming languages were object-oriented.
a) True
b) False

True
False

Answers

Answer:

False.

Object orientation is a paradigm that came later.

Other Questions
Select the correct answer. Owen has enough materials to build up to 10 birdhouses in shop class. Each birdhouse needs 12 square feet of wood. The function W(b) = 12b represents the total amount of wood that Owen would need to build b birdhouses. What domain and range are reasonable for the function? A. D: 0 b 10 R: 12 W(b) 120 B. D: 10 b 12 R: 0 W(b) 120 C. D: 0 b 120 R: 0 W(b) 10 D. D: 0 b 10 R: 0 W(b) 120 I WILL MARK BRAINLIESTWhich Linear function is represented by the graph?f(x)-2x +1f(x)= -1/2x +1f(x)= 1/2x + 1f(x)= 2x + 1 please help me with the image below Somebody help me answer the question please Graph each linear equation that passes through the given pair of points. Use graph paper. 1. (2,2) and (4,5) 2. (0,1/2) and (2,3/2)3. (-1,2) and (5,0)4(-5,-3) and (-3,5) Networks can be made of bonded ____________________ or ____________________. 3. Which of the following is NOT a use for a ladle?A.Dip foodsB.Stir foodsC.Control portionsD.A replacement for traditional flatware Who was the first Catholic emperor of the West?King Richard the Lion HeartedCharlemagneAlfred of the DanesKing Charles II The next question refers to the following passage. The sentences have been numbered to help you identify them more easily. (1) As she was driving to visit her twin, Jayla had a strange feeling that something bad was going to happen. (2) Meanwhile, Kayla had the same exact premonition. (3) Worried about her sister, Kayla called Jayla's cell phone. (4) Because she took her eyes off the road to answer the phone call, Jayla lost control of her car and crashed through the front of Kayla's house. Which sentence features an introductory clause that explains why the main action happened? (5 points) Sentence 1 Sentence 2 Sentence 3 Sentence 4 I will give brainliest just answer please. Just answer the first one or both of them please Where does fertilization of the egg occurs? help me pleaseeeee :) i needs help FAST plsmatch the following wars to the effects they produced what is the difference of a solid and gas. Complete the equation of the line whose slope is -2 and y-intercept is (0,-8)?y =I will give brainliest so can someone of u say the answer becoz I couldn't find the answer I am new here the question is given 2. Which of the following would be an example of a "Call to Adventure?"* 7 points O A. The Hero defeats his arch enemy B. The Hero returns to his world with a boon (reward) that can be shared by all O C. The Hero is reluctant to embark (start) on a new journey O D. The Hero receives an invitation or challenge that disrupts his ordinary worldASAP PLEASE !!?? -0.25 + 3 1/6 + 2 1/12plz help me with this. PLEASE HELP ME. THIS IS DUE TODAY The table shows the relationship between X and Y.X | Y3 | 163.56 | 32711 | 599.5Which equation models this relationship?A. y = 53xB. y = 53.5xC. y = 54xD. y = 54.5xPLEASE ANSWER I NEED THIS THE ANSWER NOW Solve this equation: 123(3x5)=12(2x+1)