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
Step2247 [10]
3 years ago
14

opy the code below into the coderunner window. Debug the code so that it outputs the verses correctly. a = input("Enter an anima

l: ") s = input ("Enter a sound: ") e = "E" print ("Old Macdonald had a farm, " + e) print ("And on his farm he had a" + a + "," + e) print ("With a " + a + "-" + a + " here and a" + s + "-" + s + " there") print ("Here a "+ s+ " there a " +s) print ("Everywhere a" + s + "-" + a ) print ("Old Macdonald had a farm," + e)\
Computers and Technology
1 answer:
Inessa05 [86]3 years ago
6 0

This code runs correct if you put every statement on a new line. You will want to replace e = "E" with e = "E-I-E-I-O" and add some spaces in the strings here and there so that the text is properly formatted. That'll be obvious after you run it for the first time.

You might be interested in
Write a Boolean expression that tests if the value stored in the variable num1 is equal to the value stored in the variable num2
Alenkinab [10]

Answer:

num1 = int(input("Enter value: "))

num2 = int(input("Enter value: "))

if num1 == num2:

   print("Equals.")

else:

   print("Unequal.")

Explanation:

6 0
2 years ago
Question 2Write a MIPS assembly implementation of the following C/C++ code. Assume small, unsigned integer arithmetic (no range
Licemer1 [7]

Answer:

Please kindly check explainations for the code.

Explanation:

lw $t1, Num1

lw $t2, Num2

lw $t3, Num3

blt $t1, $t2, if

beq $t1, $t2, elseif

else:

add $t0, $t3, 5

sw $t0, Result

endif:

#.....other statements after if-elseif-else

if:

sw $t1, Result

b endif

elseif:

ble $t2, $t3, if2

or $t0, $t1, $t3

sw $t0, Result

b endif

if2:

and $t0, $t2, $t3

sw $t0, Result

b endif

Go to attachment for the onscreen code.

4 0
3 years ago
WILL GIVE BRAINLIEST!!!!!!!!!
sukhopar [10]

Answer:

True

Explanation:

7 0
2 years ago
What is input process<br>​
riadik2000 [5.3K]

Answer:

describing the structure of an information processing program or another process. Many introductory programming and systems analysis texts introduce this as the most basic structure for describing a process.

Explanation:

  • A requirement from the environment (input)
  • A computation based on the requirement (process)
  • A provision for the environment (output)

Example: A small engineering firm believes there are problems with its hiring process. Several of the junior engineers that have been hired remained at the firm for less than one year. This is a considerable cost to the firm, since recruiting and training new engineers is time consuming and expensive. The human resources manager decides to put together a group of people with extensive experience hiring new engineers. One of their first tasks is to produce an input-output model of the hiring process. They generate the following.

4 0
3 years ago
Create a program that contains 4 methods / functions... main(), getTestScores(), calcAverage(), and displayAverage(). The main()
jeyben [28]

Answer:

import java.util.Scanner;

public class  num6{

   static int getTestScores(){

       System.out.println("Enter the Score");

       Scanner in = new Scanner(System.in);

       int score = in.nextInt();

       return score;

   }

   static double calcAverage(int score1, int score2, int score3){

       return (score1+score2+score3)/3;

   }

   static void displayAverage(double ave){

       System.out.println("The Average is "+ave);

   }

   public static void main(String[] args) {

       int num1 = getTestScores();

       int num2 = getTestScores();

       int num3 = getTestScores();

       //Calling Calculate Average

       double average = calcAverage(num1,num2,num3);

       //Calling displayAverage

       displayAverage(average);

   }

}

Explanation:

  • Using Java programming Language
  • Create the four methods
  • getTestScores() Uses the Scanner Class to receive an in variable and return it
  • calcAverage() accepts three ints as parameter calculates their average and return it
  • displayAverage() Accepts a double and prints it out with a concatenated string as message
  • In the Main Method, getTestScores is called three times to obtain three numbers from the user
  • calAverage is called and handed the three numbers
  • printAverage is called to output the calculated average
8 0
2 years ago
Other questions:
  • Isabella's manager has asked her to write up a _____ that describes their company's interest in developing a custom software sol
    13·1 answer
  • Briefly define "address space" and discuss its major tradeoffs (advantages/costs). What problem is it addressing?
    10·1 answer
  • How do I use this without the spring?
    6·1 answer
  • Identify any eight new programming languages and classify them based on their functionality.
    14·2 answers
  • Why are I/O (input/output operations) important in database environment?
    8·1 answer
  • In dynamic programming, the technique of storing the previously calculated values is called A. Saving value property B. Storing
    7·1 answer
  • ANSWER QUICKLY PLEASE
    7·1 answer
  • I need help for my computer science class I would appreciate it
    11·1 answer
  • What is the full form of html​
    13·2 answers
  • The _____ describes how data actually moves from an application on one computer to an application on another networked computer.
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!