Question: 1. 2. Write a pseudocode algorithm for a program that asks the user for the number gallons of gas used and the number of
1. 2. Write a pseudocode algorithm for a program that asks the user for the number gallons of gas used and the number of miles driven on a trip. Then the program should compute the miles per gallon for the trip and print that value with an appropriate label. Come up with 3 test cases for this algorithm and note those values in the table below. Use integer values for the inputs but include the fractional parts in the miles per gallon. Gallons of gas used Miles Traveled Note: You will implement this algorithm in lab. Based on the information on this webpage: Miles per Gallon Get a string that matches the original string except that it is all lowercase: Get a string that contained a specific portion of the original string: Get a string that matches the original string with all spaces at the beginning and end removed: Get a string that matches the original string except that all of the 'm's have been replaced with *M's:
Step by Step Solution
3.50 Rating (163 Votes )
There are 3 Steps involved in it
Here is a pseudocode algorithm for the program you described 1 Display a message to prompt the user ... View full answer
Get step-by-step solutions from verified subject matter experts
