1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Nutka1998 [239]
4 years ago
12

Create a new method in your language called Times Print. This should be a void method. It should accept exactly two numeric valu

es as input, X and Y. Inside the body, it should display text like, "The value of X times Y is Z," where Z=X*Y. It should accomplish no other tasks inside the body. Call this method inside your main (or equivalent starting point) three times, each with different inputs. Check that the program runs and the output matches what you expect. Embed screenshots of the code and the program running.

Computers and Technology
1 answer:
user100 [1]4 years ago
8 0

Answer:

The code commented is given below, also the lines that start with # are comments that explains the code.

# Create a function named times_print that receives 2 values x and y

def times_print(x, y):

   # Print the formatted string

   print("The value of {} times {} is {}".format(x,y,x*y))

# Create the main function

def main():

   # Call the funciton times_print 3 times with different values

   times_print(2,3)

   times_print(4,5)

   times_print(5,6)

# Execute the main function

main()

Explanation:

The code was written using Python 3.5, and here I attach the screenshots of the program running:

You might be interested in
Write a program that produces this output:
AveGali [126]

Answer:

void printC()  

{  

   int i, j;  

   for (i = 0; i < 4; i++) //i indicate row number. Here we have 5 rows

       {  

         printf("C"); //print C for every row  

         for (j = 0; j < 6; j++) //j indicate column number. Here we have 7 Rows

         {  

           if (i == 0 || i == 4) //For first and last row  

               printf("C"); //print 'CCCCCCC'

          else if (i = 1|| i= 3) //for Second forth row  

                printf("C        +      +"); //print 'C    +    +'

          else if (i = 2) For second row  

                printf("C       +++++"); //print 'C +++++'

           else

               continue; //to jump to next iteration

         }  

         printf("\n"); // print in next line

}  

}

4 0
3 years ago
A database admin uses a SHOW statement to retrieve information about objects in a database. This information is contained in a _
vlada-n [284]

Answer:

motherboard

Explanation:

i think

3 0
3 years ago
What is the portion of the PowerPoint window that contains the current slide, total slides, zoom options, and various shortcuts
telo118 [61]
Normal view is the answer
7 0
4 years ago
Forgot this website exsited wsp
Mariulka [41]

Answer:

no

Explanation:

5 0
3 years ago
Read 2 more answers
Jiz<br>Active<br>2<br>3<br>- 2(7 - 15)<br>What is the value of<br>4​
-Dominant- [34]

Answer: I think it is c

Explanation: hope this helps

3 0
3 years ago
Read 2 more answers
Other questions:
  • The ListIterator interface
    13·1 answer
  • . What is the difference between subnetting and supernetting?
    13·1 answer
  • Write a Python function called validateCreditCard that takes 8-digit credit card number as the input parameter (string value) an
    8·1 answer
  • What are the advantages to using a linked implementation as opposed to an array implementation?
    8·1 answer
  • What is not true about field properties in Access?
    13·1 answer
  • Which of the following is not a natural resource
    11·2 answers
  • Take a minute to reflect on your thoughts and learning so far and discuss:
    13·1 answer
  • How do hand tools,Farm implements and farm equipment differ from one another
    6·1 answer
  • JAVA
    13·1 answer
  • What is the earliest age you can collect social security.
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!