You are
required to provide:-
(i) Algorithm (Flowchart or
Pseudocode) for each the following problems.
1.
Write a program that prompts the user to enter the width and
height of a rectangle and displays the perimeter and area. Here is a sample
run:
Enter the width of a rectangle: 5.25
Enter the height of a rectangle: 9.26
The perimeter is 29.02
The area is 48.62
2.SATU Terengganu charges the following rates for its customer:-
Penggunaan
|
Caj
Minima (RM) |
|
Kuantiti M3
(Meter Padu) |
Caj
Setiap M3 |
|
0 - 20.00
|
RM0.42
|
RM4.00 sebulan
|
20.1 - 40.00
|
RM0.65
|
|
40.1 - 60.00
|
RM0.90
|
|
60.1 ke atas
|
RM1.00
|
Input the amount of
water used and calculate the net amount for a customer.