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
konstantin123 [22]
2 years ago
11

Write a program that echos back any inputted integer greater than 1, and exits when a 0 is entered. Your program should use a co

nditional branch when deciding whether to echo back the integer or exit the program. It should use a jump when looping back up to run the input+echo again.
Computers and Technology
1 answer:
denpristay [2]2 years ago
7 0

Answer:

MIPS Code:

.data

newline: .asciiz "\n" #newline variable

.text

MAINLOOP:

li $v0, 5 #syscall to get user interger and store in $v0

syscall

add $a0, $zero, $v0 #moving the user input to $a0 from $v0

beq $a0, 0, EXIT #branching to EXIT when $a0 is 0

li $v0, 1 #syscall to print integer in $a0

syscall

li $v0, 4 #syscall to print newline

la $a0, newline

syscall

j MAINLOOP #jumping to MAINLOOP

EXIT:

Sample Output:

6

6

7

7

3

3

0

You might be interested in
ASAP PLS HELP: I’ll give brainliest if you u answer them all correctly!!
ra1l [238]

Answer:

1 c

2 a

3 c

4 b

5 c

6 b

7 d

8 a

9 d

10 b

6 0
3 years ago
Read 2 more answers
A group of users can perform certain operations on a shared workbook. Which option helps them to update and track changes in the
irina1246 [14]

The “Allow changes by more than one user at the same time” option.


In a group of users, it is very important to create a shared workbook so that several people are able to update information and track changes in the workbook at the same time. To do so, one should click on the review tab of the excel sheet and select share workbook. On the editing tab of the share workbook dialog box, select the Allow changes by more than one user at the same time check box. Go ahead and click the advanced tab and select option you would want to use and then click OK

 






4 0
3 years ago
Where are methods listed in a UML class diagram showing three parts?
denis23 [38]

Answer:

the bottom third

Explanation:

Check out the exampe below.

swim() would be an example of a method.

3 0
2 years ago
What does different screen size have to do with the display apperance of sites?
lesantik [10]
Display quality, or fit
7 0
2 years ago
You want to use your Windows workstation to browse the websites on the internet. You use a broadband DSL connection to access th
xxTIMURxx [149]

Answer:

IP

Explanation:

8 0
3 years ago
Other questions:
  • Timing circuits are a crucial component of VLSI chips. Here’s a simple model of such a timing circuit. Consider a complete balan
    10·1 answer
  • 1. Mobile devices have a _________ viewport that displays a web page content that fits within a mobile screen.
    11·1 answer
  • The picture that graphically represents the items you use in Windows is called a/an
    12·2 answers
  • Tom is the aerobics coordinator at a fitness center. He needs a more efficient way for his instructors to share information. Cla
    13·2 answers
  • VOTE!
    11·1 answer
  • Programmers should strive to _____. increase coupling increase cohesion both of the above neither a nor b
    7·1 answer
  • Read each statement below. If the statement describes a peer-to-peer network, put a P next to it. If the statement describes a s
    12·1 answer
  • Devices which are used to receive data from central processing unit are classified as
    11·1 answer
  • (Count the occurrences of words in a text file) Rewrite Listing 21.9 to read the text from a text file. The text file is passed
    10·1 answer
  • Raw materials have two basic types what are the 2?
    11·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!