Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Objective: Practice MIPS loops, conditionals, functions. Instructions Create a MIPS program that fulfills the following specifications: 1. use the dialog syscall (#54) to input a

image text in transcribed

Objective: Practice MIPS loops, conditionals, functions. Instructions Create a MIPS program that fulfills the following specifications: 1. use the dialog syscall (#54) to input a string from the user 2. call a function which counts the number of characters and number of words in the string and returns these in $v0 and $v1; store these in memory 3. output (console the string and counts to the user (see example below) 4. repeat from 1 until the user enters a blank string or hits "cancel" 5. additionally, use $s1 somewhere in your function so that you must save it on the stack at the top of your function and restore it before the function exits; Of course this function could be written without using an s register, but this is good practice in using the stack. 6. output a dialog message (syscall #59) to say goodbye before the program ends Note: space is a character, so it should be counted

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Fundamentals Study Guide

Authors: Dr. Sergio Pisano

1st Edition

B09K1WW84J, 979-8985115307

More Books

Students also viewed these Databases questions

Question

Explain the business benefits of a data-driven website.

Answered: 1 week ago

Question

=+22.4 Why is a highly coupled module difficult to unit test?

Answered: 1 week ago

Question

Did you open with an issue explanation?

Answered: 1 week ago