-
-
Save fieldju/905287 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; | |
; test script for programming assignment 1 | |
; spring term, 2011 | |
"Test Script" | |
"Values should be repeated, first your result, then correct result" | |
(map (lambda (x) (begin (display x) (newline))) | |
(list | |
(plusOne 42) | |
43 | |
(plusOne 0) | |
1 | |
(addToEnd 3 '(1 2)) | |
'(1 2 3) | |
(addToEnd 3 '()) | |
'(3) | |
(myReverse '(a b c)) | |
'(c b a) | |
(myReverse '(a)) | |
'(a) | |
(myReverse '()) | |
'() | |
(myCount 3 '(1 2 3)) | |
1 | |
(countAll 3 '(1 3 (3 4) (3 4))) | |
3 | |
(insert 2 '(1 3 5)) | |
'(1 2 3 5) | |
(insert 0 '(1 3 5)) | |
'(0 1 3 5) | |
(insert 6 '(1 3 5)) | |
'(1 3 5 6) | |
(insert 3 '()) | |
'(3) | |
(setAdd 3 '()) | |
'(3) | |
(setAdd 3 '(1 2 4)) | |
'(3 1 2 4) | |
(setAdd 3 '(1 2 3 4)) | |
'(1 2 3 4) | |
(setIncludes 3 '(1 2 4)) | |
#f | |
(setIncludes 3 '(1 2 3 4)) | |
#t | |
(setIncludes 3 '()) | |
#f | |
(setRemove 3 '(1 2 4)) | |
'(1 2 4) | |
(setRemove 3 '(1 2 3 4)) | |
'(1 2 4) | |
(setRemove 3 '()) | |
'() | |
)) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment