diff options
Diffstat (limited to 'CST116-Ch10-Debugging/CST116-Ch10-Debugging-Williams-Pseudocode.txt')
| -rw-r--r-- | CST116-Ch10-Debugging/CST116-Ch10-Debugging-Williams-Pseudocode.txt | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/CST116-Ch10-Debugging/CST116-Ch10-Debugging-Williams-Pseudocode.txt b/CST116-Ch10-Debugging/CST116-Ch10-Debugging-Williams-Pseudocode.txt new file mode 100644 index 0000000..5ee897c --- /dev/null +++ b/CST116-Ch10-Debugging/CST116-Ch10-Debugging-Williams-Pseudocode.txt @@ -0,0 +1,28 @@ +program start: + +create a constant for SIZE and set it to 10 +create int arrays of size SIZE for varX, varY, and varZ + +run GetAndDisplayWelcomeInfo +run FunctionOne + +run FunctionTwo +set varZ[SIZE-1] to -99 +run PrintFunction + +program end + + +GetandDisplayWelcomeInfo: +create an array NAME containing 2 chars of size 20 +get the user's first and last name and store them in NAME +print a welcome message addressing the user by name + +FunctionOne: +for each value in varX[i], set varY[i] to varX[i] + 100 + +FunctionTwo: +for each value in varX[i], set varZ[i] to varX[i] + varY[i] + +PrintFunction(varX,varY,varZ): +print varX, varY, and varZ in a simple table
\ No newline at end of file |