aboutsummaryrefslogtreecommitdiff
path: root/CST116-Ch9-Debugging/CST116-CH9-pseudo-code-Cyrus.txt
blob: aaa5bf15f107059190ee66170d7f5ad897c88eea (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
declare int age and assign 0
declare int days and assign 0

assign age the value calculated by the getAge function
 getAge takes the value provided by the user and returns it

assign days the value calculated by the calcDays function using age as a passed in variable for the calculation
 calcDays takes the value passed in (age) and creates a local variable (days) which it then assigns the value of (age * DAYS_PER_YEAR).
 calcDays returns this value

using the PrintResults function, tell the user their age in years, and the number of days this is equivalent to which was calculated in calcDays.