FLOWCHART DRY RUN
LOOP · TRACE TABLE · OUTPUT
prostudypk.com
Sum of 1 to 5
Yes
No
Start
sum = 0, i = 1
i ≤ 5 ?
sum = sum + i
i = i + 1
Print sum
End
i
sum
i ≤ 5 ?
Output: —
i
=
counter
sum =
running total
loop round
1. Flowchart Symbols
Start / End
Process
Decision
Input / Output
2. Dry Run
At every step write the values of the variables in a table
1 + 2 + 3 + 4 + 5 =
15
3. Remember
Condition false → loop ends
Diamond = sawal (Yes / No)
MATRIC COMPUTER · PROBLEM SOLVING · PUNJAB BOARDS
‹ Labs
↺
❚❚
1×
Next ›