Create a procedure named CalcGrade that receives an integer value between 0 and 75, and returns...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Create a procedure named CalcGrade that receives an integer value between 0 and 75, and returns a single capital letter in the AL register. Preserve all other register values between calls to the procedure. The letter returned by the procedure should be displayed and should be according to the following ranges: Score 70 to 75 Grade A Score 60 to 69 Grade B Score 50 to 59 Grade C Score 0 to 49 Grade F Write a test program that 1. asks the user to enter integer between 0 and 75, inclusive. If the user enters invalid number, please display error message. 2. Pass it to the CalcGrade procedure. 3. Repeat steps 1 and 2 three times so that you collect three scores from the user and display the respective grade for each score. Create a procedure named CalcGrade that receives an integer value between 0 and 75, and returns a single capital letter in the AL register. Preserve all other register values between calls to the procedure. The letter returned by the procedure should be displayed and should be according to the following ranges: Score 70 to 75 Grade A Score 60 to 69 Grade B Score 50 to 59 Grade C Score 0 to 49 Grade F Write a test program that 1. asks the user to enter integer between 0 and 75, inclusive. If the user enters invalid number, please display error message. 2. Pass it to the CalcGrade procedure. 3. Repeat steps 1 and 2 three times so that you collect three scores from the user and display the respective grade for each score.
Expert Answer:
Answer rating: 100% (QA)
data str1 BYTE The integer score is 0 str2 BYTE The letter grade is 0 str3 BYTE Error Message 0 code ... View the full answer
Related Book For
Database Systems Design Implementation and Management
ISBN: 978-1285196145
11th edition
Authors: Carlos Coronel, Steven Morris
Posted Date:
Students also viewed these programming questions
-
Create a procedure named prc_cus_balance_update that will take the invoice number as a parameter and update the customer balance.
-
Create a procedure named FindLargest that receives two parameters: a pointer to a signed doubleword array and the array's length. The procedure must return the value of the largest array member in...
-
Create a procedure named FindThrees that returns 1 if an array has three consecutive values of 3 somewhere in the array. Otherwise, return 0. The procedure's input parameter list contains a pointer...
-
Which properties of the Clean annotation must be true for the following to compile? (Choose three.) A. The annotation must contain exactly one element. B. The annotation must contain an element named...
-
How much revenue does it take to maintain a cricket club? The following table shows annual income for 18 first-class clubs that engage in league play. (a) Calculate the mean and median. (b) Describe...
-
Assume that acetyl CoA containing a 14C isotopic label in the carboxyl carbon atom is used as starting material for the biosynthesis of mevalonate, as shown in figure. At what positions in mevalonate...
-
Haupt Consulting, Inc., began operations and completed the following transactions during the first half of December: Requirements 1. Analyze the effects of Haupt Consultings transactions on the...
-
Andrew Weiman and Mei Lee are discussing accounting for income taxes. They are currently studying a schedule of taxable and deductible amounts that will arise in the future as a result of existing...
-
1. Predict/explain how you think the total momentum of an elastic collision between 2 objects is conserved. 2. Utilizing the Law of Conservation of Momentum and the initial conditions for the four...
-
John and Sandy Ferguson got married eight years ago and have a seven-year-old daughter, Samantha. In 2020, John worked as a computer technician at a local university earning a salary of $152,000, and...
-
Assume Josephine and Lorenzo have no itemized deductions. Fill out and prepare Form 1040 FACTS: Your clients are a married couple who file a joint return: Josephine Burns (born 2/5/1974) Lorenzo...
-
After the fiasco of the negotiations with Shirley and Matilda Fishing Pty Ltd, Francisco decided that selling his fishing vessel was just too much trouble. He has decided that the best way to make...
-
Information on four potential projects is given below: Projects A B C D Investment required $(350,000) $(390,000) $(450,000) $(480,000) Present value of cash inflows 535,000 590,000 670,000 730,000...
-
Multiply: (1k+ 9)( 1k 9) =
-
Determining the most equitable method of judicial selection is a nuanced task influenced by factors such as transparency, public participation, and judicial independence. From my standpoint, the...
-
Because he has a gambling problem and owes a great deal of money to some scary people, Jason is desperate for money. His girlfriend Samantha works at a local bar. She is terrified that someone is...
-
Consider the following simple snippet of MIPS code, which transfers a value from memory location A to memory location A + 4000 (where A is stored in $s1): lw $s0, 0 ($s1) sw $s0, 4000 ($s1) (a)...
-
The age-old saying for investing is "buy low and sell high," but this is easier said than done. Investors who panic about falling prices sell their investments, which in turn lowers the price and...
-
Using the INVOICE table structure shown in Table P6.3, do the following: a. Write the relational schema, draw its dependency diagram and identify all dependencies, including all partial and...
-
Write the trigger to update the CUST_BALANCE in the CUSTOMER table when a new invoice record is entered. (Assume that the sale is a credit sale.) Test the trigger using the following new INVOICE...
-
In Chapter 4, you saw the creation of the Tiny College database design. That design reflected such business rules as a professor may advise many students and a professor may chair one department....
-
A hospitals records show that the cost of carrying out health checks in the last five accounting periods has been as follows: Using the highlow method and ignoring inflation, the estimated cost of...
-
Intermediate: Cost estimation using the linear regression formula. The management accountant at Josephine Ltd is trying to predict the quarterly total maintenance cost for a group of similar...
-
The budget for the production cost of a new product was based on the following assumptions: (i) Time for the 1 st batch of output = 10 hours (ii) Learning rate = 80 per cent (iii) Learning will cease...
Study smarter with the SolutionInn App