CS1 Standard Demo Page

The following text was written to the standard output stream when the NumberList program was executed from IntelliJ.

>>> help
HELP - display a menu of commands
DISPLAY - display the list of numbers
PRINT - print a number (FIRST;LAST;nth)
SWAP - exchange two elements (nth;mth)
ADD - add a number to the list (FIRST;LAST)
EXIT - terminate execution of the program
>>> display
2
5
9
19
27
6
28
4
10
17
20
21
42
>>> print first
2
>>> print last
42
>>> print 3
9
>>> print 18
0
>>> swap 5 7
>>> display
2
5
9
19
28
6
27
4
10
17
20
21
42
>>> swap 1 18
>>> display
0
5
9
19
28
6
27
4
10
17
20
21
42
>>> help
HELP - display a menu of commands
DISPLAY - display the list of numbers
PRINT - print a number (FIRST;LAST;nth)
SWAP - exchange two elements (nth;mth)
ADD - add a number to the list (FIRST;LAST)
EXIT - terminate execution of the program
>>> add first 100
>>> add last 200
>>> shownumbers
### Unrecognizable command: shownumbers
>>> display
100
0
5
9
19
28
6
27
4
10
17
20
21
42
200
>>> exit