Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 1

FLOW CHART WORK

Create flow charts for the following Pseudocodes

Ducks = 0
1) Print ‘Enter the student’s mark and the Read Runs
pass mark’ WHILE Runs <> -1 DO
Read SM, PM Total = Total + Runs
IF SM >= PM THEN IF Runs = 0 THEN
Print ‘Pass’ Ducks = Ducks + 1
ELSE ENDIF
Print ‘Fail’ Read Runs
ENDIF ENDWHILE
Read Extras
2) Print ‘Enter the price and quantity’ Total = Total + Extras
Read Price, Qty Print ‘Total runs = ‘, Total
Total = Price * Qty Print ‘Ducks =’, Ducks
IF total >= 100 THEN
Discount = Total * 10/100 7) Max = 0
Else Read Name, Pop
Discount = Total * 5/100 While Pop <> 0 DO
ENDIF IF POP > max THEN
Print Total Max = Pop
Print Discount Nam = Name
ENDIF
3) Print ‘BDS’, ‘US’ Read Name, Pop
FOR BDS = 20 T0 200 step 5 DO ENDWHILE
US = BDS / 2 Print Nam
Print BDS, US
END FOR 8) Max = 0
FOR S = 1 To 30 DO
4) Print ‘Miles’, ‘Kilometers’ Print ‘Enter a score’
FOR M = 1 to 25 DO Read Score
KM = M * 1.61 IF Score > Max THEN
Print M, KM Max = Score
END FOR ENDIF
ENDFOR
5) Total = 0 Print ‘Highest Score’, Max
Days = 0
Read ‘Rainfall’ 9) Read Hours
WHILE Rainfall <> 999 DO IF Hours <= 2 THEN
Days = Days + 1 Fee = Hours * 90
Total = Total + Rainfall Else
Read Rainfall IF Hours > 2 AND Hours <= 6 THEN
ENDWHILE Fee = Hours * 75
IF Days > 0 THEN Else
AVERAGE = Total/ Days Fee = Hours * 60
Print AVERAGE ENDIF
END IF ENDIF
Print Hours, Fee

6) Total = 0

You might also like