This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: Input speed // Get the drivers speed limit. Display “Please enter the speed limit.” Input speedLimit // Correct any speed limit errors. While speedLimit < 20 OR > 70 Display “ERROR-The speed limit must be between 20 MPH and 70 MPH.” Display “Please enter again.” Input speedLimit End While // Get MPH over the limit (if any). If speed > speedLimit Then Call mphOver (speed, speedLimit) Else Display “Your speed is not over the speed limit.” End If Module mphOver (driversSpeed, legalLimit) Declare Integer amountOverLimit Set amountOverLimit = driversSpeed – legalLimit Display “You are going”, amountOverLimit, “over the speed limit.” End Module...
View Full Document
This note was uploaded on 01/19/2012 for the course COMPUTER S 100 taught by Professor Brown during the Spring '11 term at Strayer.
- Spring '11