Question: 1. Write a MIPS program using MARS IDE to accept a string from the user and (10 points) a) Find the length of the string



1. Write a MIPS program using MARS IDE to accept a string from the user and (10 points) a) Find the length of the string and display the string length (10 points). b) Using the given ascii value chart find the number of words in the string. (20 points) c) Using the given ascii value chart find if the string ends with a full stop. If ends with a full stop, display the message "Yes sentence" (10 points) d) Count the number of Capital letters in the sentence and display the count (10 points) e) Count the occurrences of letter 'i' in the sentence and display the count (10 points) Example input and output 1 If the user enters "My name is Ranjidha" Output should be Length of string is =19 Number of words in the sentence is = 4 Not a complete sentence Number of Capital letters 2 Occurrence of letter 'i' = 2 Example input and output 2 If the user enters "My name is ranjidha." Output should be Length of string is = 20 Number of words in the sentence is = 4 Yes a complete sentence. Number of Capital letters = 1 Occurrence of letter 'i' = 2
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
