1 Algorithms Practice Topics In-Class Project: Tip Calculator In-Class Project: Drawing a Rectangle.
-
Upload
alvin-underwood -
Category
Documents
-
view
215 -
download
0
Transcript of 1 Algorithms Practice Topics In-Class Project: Tip Calculator In-Class Project: Drawing a Rectangle.
![Page 1: 1 Algorithms Practice Topics In-Class Project: Tip Calculator In-Class Project: Drawing a Rectangle.](https://reader036.fdocuments.us/reader036/viewer/2022081813/5697bff11a28abf838cbb3bc/html5/thumbnails/1.jpg)
1
Algorithms Practice
Topics
In-Class Project: Tip Calculator In-Class Project: Drawing a Rectangle
![Page 2: 1 Algorithms Practice Topics In-Class Project: Tip Calculator In-Class Project: Drawing a Rectangle.](https://reader036.fdocuments.us/reader036/viewer/2022081813/5697bff11a28abf838cbb3bc/html5/thumbnails/2.jpg)
2
Writing Algorithms from Scratch
Given a problem statement, we are going to write the corresponding generic algorithm for the solution.
We will use the following procedure: Determine the algorithm inputs and outputs Develop the pseudocode
![Page 3: 1 Algorithms Practice Topics In-Class Project: Tip Calculator In-Class Project: Drawing a Rectangle.](https://reader036.fdocuments.us/reader036/viewer/2022081813/5697bff11a28abf838cbb3bc/html5/thumbnails/3.jpg)
3
Tip Calculator
Problem: Write an interactive program to calculate the dollar amount of tip on a restaurant bill given the percentage of tip. You should allow for changes in the total price of the bill and the tip percentage. Error checking should be done to be sure that the amount of the bill is greater than 0.
![Page 4: 1 Algorithms Practice Topics In-Class Project: Tip Calculator In-Class Project: Drawing a Rectangle.](https://reader036.fdocuments.us/reader036/viewer/2022081813/5697bff11a28abf838cbb3bc/html5/thumbnails/4.jpg)
4
Drawing a Rectangle
Problem: Write an interactive program that will draw a solid rectangle of asterisks (*). You should allow for changes in the height and width of the rectangle. Error checking must be done to be sure that the dimensions are greater than zero.