basic101 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.rspec +2 -0
- data/.simplecov +1 -0
- data/.yardopts +7 -0
- data/Changelog.md +3 -0
- data/Gemfile +12 -0
- data/Gemfile.lock +75 -0
- data/LICENSE.md +9 -0
- data/README.md +193 -0
- data/Rakefile +14 -0
- data/VERSION +1 -0
- data/bin/basic101 +10 -0
- data/lib/basic101/abs_function.rb +19 -0
- data/lib/basic101/argument_checker.rb +61 -0
- data/lib/basic101/arguments.rb +32 -0
- data/lib/basic101/array_reference.rb +52 -0
- data/lib/basic101/asc_function.rb +17 -0
- data/lib/basic101/basic_array.rb +69 -0
- data/lib/basic101/basic_comparisons.rb +20 -0
- data/lib/basic101/basic_float.rb +48 -0
- data/lib/basic101/basic_integer.rb +48 -0
- data/lib/basic101/basic_math.rb +22 -0
- data/lib/basic101/basic_numeric.rb +96 -0
- data/lib/basic101/basic_object.rb +35 -0
- data/lib/basic101/basic_string.rb +85 -0
- data/lib/basic101/binary_operation.rb +32 -0
- data/lib/basic101/binary_operations.rb +26 -0
- data/lib/basic101/built_in_functions.rb +31 -0
- data/lib/basic101/chr_function.rb +17 -0
- data/lib/basic101/cos_function.rb +17 -0
- data/lib/basic101/data_statement.rb +24 -0
- data/lib/basic101/define_function_statement.rb +23 -0
- data/lib/basic101/dim_statement.rb +25 -0
- data/lib/basic101/else_statement.rb +22 -0
- data/lib/basic101/end_statement.rb +13 -0
- data/lib/basic101/endif_statement.rb +19 -0
- data/lib/basic101/errors.rb +50 -0
- data/lib/basic101/exp_function.rb +17 -0
- data/lib/basic101/for_stack.rb +48 -0
- data/lib/basic101/for_statement.rb +57 -0
- data/lib/basic101/function.rb +11 -0
- data/lib/basic101/function_call.rb +32 -0
- data/lib/basic101/function_identifier.rb +8 -0
- data/lib/basic101/functions.rb +39 -0
- data/lib/basic101/gosub_statement.rb +23 -0
- data/lib/basic101/goto_statement.rb +23 -0
- data/lib/basic101/identifier.rb +23 -0
- data/lib/basic101/identity.rb +18 -0
- data/lib/basic101/if_statement.rb +31 -0
- data/lib/basic101/input.rb +44 -0
- data/lib/basic101/input_reader.rb +55 -0
- data/lib/basic101/input_statement.rb +46 -0
- data/lib/basic101/int_function.rb +17 -0
- data/lib/basic101/left_function.rb +19 -0
- data/lib/basic101/len_function.rb +18 -0
- data/lib/basic101/let_statement.rb +24 -0
- data/lib/basic101/line.rb +32 -0
- data/lib/basic101/log_function.rb +17 -0
- data/lib/basic101/main.rb +24 -0
- data/lib/basic101/mid_function.rb +20 -0
- data/lib/basic101/negate_operation.rb +21 -0
- data/lib/basic101/next_statement.rb +34 -0
- data/lib/basic101/not_operation.rb +23 -0
- data/lib/basic101/null_prompt_delimeter.rb +12 -0
- data/lib/basic101/null_transcript.rb +20 -0
- data/lib/basic101/numeric_identifier.rb +16 -0
- data/lib/basic101/on_goto_statement.rb +29 -0
- data/lib/basic101/output.rb +73 -0
- data/lib/basic101/parser.rb +457 -0
- data/lib/basic101/power_operation.rb +24 -0
- data/lib/basic101/print_comma.rb +20 -0
- data/lib/basic101/print_semicolon.rb +19 -0
- data/lib/basic101/print_statement.rb +33 -0
- data/lib/basic101/program.rb +100 -0
- data/lib/basic101/program_counter.rb +52 -0
- data/lib/basic101/prompt_delimeter.rb +13 -0
- data/lib/basic101/randomize_statement.rb +13 -0
- data/lib/basic101/read_statement.rb +25 -0
- data/lib/basic101/reference.rb +25 -0
- data/lib/basic101/remark_statement.rb +12 -0
- data/lib/basic101/restore_statement.rb +23 -0
- data/lib/basic101/return_statement.rb +16 -0
- data/lib/basic101/right_function.rb +19 -0
- data/lib/basic101/rnd_function.rb +24 -0
- data/lib/basic101/runtime.rb +132 -0
- data/lib/basic101/scalar_reference.rb +19 -0
- data/lib/basic101/sgn_function.rb +17 -0
- data/lib/basic101/sin_function.rb +17 -0
- data/lib/basic101/sqr_function.rb +17 -0
- data/lib/basic101/statement.rb +36 -0
- data/lib/basic101/stop_statement.rb +14 -0
- data/lib/basic101/str_function.rb +16 -0
- data/lib/basic101/string_identifier.rb +16 -0
- data/lib/basic101/tab.rb +18 -0
- data/lib/basic101/tab_function.rb +17 -0
- data/lib/basic101/tan_function.rb +17 -0
- data/lib/basic101/transcript.rb +37 -0
- data/lib/basic101/transform.rb +264 -0
- data/lib/basic101/user_defined_function.rb +54 -0
- data/lib/basic101/val_function.rb +16 -0
- data/lib/basic101.rb +93 -0
- data/rake_tasks/default.rake +1 -0
- data/rake_tasks/integration.rake +8 -0
- data/rake_tasks/jeweler.rake +28 -0
- data/rake_tasks/spec.rake +8 -0
- data/rake_tasks/test.rake +2 -0
- data/rake_tasks/yard.rake +3 -0
- data/test/integration/arguments.rb +25 -0
- data/test/integration/errors.rb +7 -0
- data/test/integration/integration_test.rb +28 -0
- data/test/integration/main.rb +49 -0
- data/test/integration/output_file.rb +40 -0
- data/test/integration/test.rb +135 -0
- data/test/integration/tests/basic_computer_games/23-match.bas +64 -0
- data/test/integration/tests/basic_computer_games/23-match.input +1 -0
- data/test/integration/tests/basic_computer_games/23-match.output +29 -0
- data/test/integration/tests/basic_computer_games/3dplot.bas +17 -0
- data/test/integration/tests/basic_computer_games/3dplot.input +0 -0
- data/test/integration/tests/basic_computer_games/3dplot.output +47 -0
- data/test/integration/tests/basic_computer_games/aceyducy.bas +100 -0
- data/test/integration/tests/basic_computer_games/aceyducy.input +8 -0
- data/test/integration/tests/basic_computer_games/aceyducy.output +78 -0
- data/test/integration/tests/basic_computer_games/amazing.bas +138 -0
- data/test/integration/tests/basic_computer_games/amazing.input +1 -0
- data/test/integration/tests/basic_computer_games/amazing.output +32 -0
- data/test/integration/tests/basic_computer_games/animal.bas +71 -0
- data/test/integration/tests/basic_computer_games/animal.input +17 -0
- data/test/integration/tests/basic_computer_games/animal.output +38 -0
- data/test/integration/tests/basic_computer_games/awari.bas +70 -0
- data/test/integration/tests/basic_computer_games/awari.input +11 -0
- data/test/integration/tests/basic_computer_games/awari.output +117 -0
- data/test/integration/tests/basic_computer_games/bagels.bas +81 -0
- data/test/integration/tests/basic_computer_games/bagels.input +12 -0
- data/test/integration/tests/basic_computer_games/bagels.output +42 -0
- data/test/integration/tests/basic_computer_games/banner.bas +94 -0
- data/test/integration/tests/basic_computer_games/banner.input +6 -0
- data/test/integration/tests/basic_computer_games/banner.output +135 -0
- data/test/integration/tests/basic_computer_games/basketbl.bas +196 -0
- data/test/integration/tests/basic_computer_games/basketbl.input +46 -0
- data/test/integration/tests/basic_computer_games/basketbl.output +509 -0
- data/test/integration/tests/basic_computer_games/batnum.bas +90 -0
- data/test/integration/tests/basic_computer_games/batnum.input +14 -0
- data/test/integration/tests/basic_computer_games/batnum.output +67 -0
- data/test/integration/tests/basic_computer_games/battle.bas +196 -0
- data/test/integration/tests/basic_computer_games/battle.input +21 -0
- data/test/integration/tests/basic_computer_games/battle.output +118 -0
- data/test/integration/tests/basic_computer_games/blackjck.bas +321 -0
- data/test/integration/tests/basic_computer_games/blackjck.input +26 -0
- data/test/integration/tests/basic_computer_games/blackjck.output +144 -0
- data/test/integration/tests/basic_computer_games/bombard.bas +93 -0
- data/test/integration/tests/basic_computer_games/bombard.input +20 -0
- data/test/integration/tests/basic_computer_games/bombard.output +175 -0
- data/test/integration/tests/basic_computer_games/bounce.bas +53 -0
- data/test/integration/tests/basic_computer_games/bounce.input +0 -0
- data/test/integration/tests/basic_computer_games/bounce.output +15 -0
- data/test/integration/tests/basic_computer_games/bowling.bas +101 -0
- data/test/integration/tests/basic_computer_games/bowling.input +23 -0
- data/test/integration/tests/basic_computer_games/bowling.output +229 -0
- data/test/integration/tests/basic_computer_games/boxing.bas +142 -0
- data/test/integration/tests/basic_computer_games/boxing.input +8 -0
- data/test/integration/tests/basic_computer_games/boxing.output +47 -0
- data/test/integration/tests/basic_computer_games/bug.bas +256 -0
- data/test/integration/tests/basic_computer_games/bug.input +17 -0
- data/test/integration/tests/basic_computer_games/bug.output +847 -0
- data/test/integration/tests/basic_computer_games/bullfght.bas +193 -0
- data/test/integration/tests/basic_computer_games/bullfght.input +4 -0
- data/test/integration/tests/basic_computer_games/bullfght.output +60 -0
- data/test/integration/tests/basic_computer_games/bullseye.bas +37 -0
- data/test/integration/tests/basic_computer_games/bullseye.input +10 -0
- data/test/integration/tests/basic_computer_games/bullseye.output +79 -0
- data/test/integration/tests/basic_computer_games/bunny.bas +40 -0
- data/test/integration/tests/basic_computer_games/bunny.input +0 -0
- data/test/integration/tests/basic_computer_games/bunny.output +67 -0
- data/test/integration/tests/basic_computer_games/buzzword.bas +25 -0
- data/test/integration/tests/basic_computer_games/buzzword.input +4 -0
- data/test/integration/tests/basic_computer_games/buzzword.output +25 -0
- data/test/integration/tests/basic_computer_games/calendar.bas +58 -0
- data/test/integration/tests/basic_computer_games/calendar.input +0 -0
- data/test/integration/tests/basic_computer_games/calendar.output +213 -0
- data/test/integration/tests/basic_computer_games/change.bas +51 -0
- data/test/integration/tests/basic_computer_games/change.input +4 -0
- data/test/integration/tests/basic_computer_games/change.output +28 -0
- data/test/integration/tests/basic_computer_games/checkers.bas +82 -0
- data/test/integration/tests/basic_computer_games/checkers.input +74 -0
- data/test/integration/tests/basic_computer_games/checkers.output +673 -0
- data/test/integration/tests/basic_computer_games/chemist.bas +27 -0
- data/test/integration/tests/basic_computer_games/chemist.input +11 -0
- data/test/integration/tests/basic_computer_games/chemist.output +54 -0
- data/test/integration/tests/basic_computer_games/chief.bas +51 -0
- data/test/integration/tests/basic_computer_games/chief.input +5 -0
- data/test/integration/tests/basic_computer_games/chief.output +19 -0
- data/test/integration/tests/basic_computer_games/chomp.bas +104 -0
- data/test/integration/tests/basic_computer_games/chomp.input +15 -0
- data/test/integration/tests/basic_computer_games/chomp.output +159 -0
- data/test/integration/tests/basic_computer_games/combat.bas +124 -0
- data/test/integration/tests/basic_computer_games/combat.input +7 -0
- data/test/integration/tests/basic_computer_games/combat.output +33 -0
- data/test/integration/tests/basic_computer_games/craps.bas +82 -0
- data/test/integration/tests/basic_computer_games/craps.input +9 -0
- data/test/integration/tests/basic_computer_games/craps.output +51 -0
- data/test/integration/tests/basic_computer_games/cube.bas +161 -0
- data/test/integration/tests/basic_computer_games/cube.input +25 -0
- data/test/integration/tests/basic_computer_games/cube.output +72 -0
- data/test/integration/tests/basic_computer_games/depthchg.bas +33 -0
- data/test/integration/tests/basic_computer_games/depthchg.input +16 -0
- data/test/integration/tests/basic_computer_games/depthchg.output +83 -0
- data/test/integration/tests/basic_computer_games/diamond.bas +27 -0
- data/test/integration/tests/basic_computer_games/diamond.input +1 -0
- data/test/integration/tests/basic_computer_games/diamond.output +65 -0
- data/test/integration/tests/basic_computer_games/dice.bas +31 -0
- data/test/integration/tests/basic_computer_games/dice.input +4 -0
- data/test/integration/tests/basic_computer_games/dice.output +46 -0
- data/test/integration/tests/basic_computer_games/digits.bas +78 -0
- data/test/integration/tests/basic_computer_games/digits.input +5 -0
- data/test/integration/tests/basic_computer_games/digits.output +70 -0
- data/test/integration/tests/basic_computer_games/evenwin1.bas +128 -0
- data/test/integration/tests/basic_computer_games/evenwin1.input +13 -0
- data/test/integration/tests/basic_computer_games/evenwin1.output +116 -0
- data/test/integration/tests/basic_computer_games/evenwin2.bas +70 -0
- data/test/integration/tests/basic_computer_games/evenwin2.input +14 -0
- data/test/integration/tests/basic_computer_games/evenwin2.output +56 -0
- data/test/integration/tests/basic_computer_games/flipflop.bas +79 -0
- data/test/integration/tests/basic_computer_games/flipflop.input +8 -0
- data/test/integration/tests/basic_computer_games/flipflop.output +45 -0
- data/test/integration/tests/basic_computer_games/footbal1.bas +298 -0
- data/test/integration/tests/basic_computer_games/footbal1.input +13 -0
- data/test/integration/tests/basic_computer_games/footbal1.output +315 -0
- data/test/integration/tests/basic_computer_games/footbal2.bas +181 -0
- data/test/integration/tests/basic_computer_games/footbal2.input +23 -0
- data/test/integration/tests/basic_computer_games/footbal2.output +318 -0
- data/test/integration/tests/basic_computer_games/furtradr.bas +170 -0
- data/test/integration/tests/basic_computer_games/furtradr.input +20 -0
- data/test/integration/tests/basic_computer_games/furtradr.output +133 -0
- data/test/integration/tests/basic_computer_games/golf.bas +244 -0
- data/test/integration/tests/basic_computer_games/golf.input +11 -0
- data/test/integration/tests/basic_computer_games/golf.output +69 -0
- data/test/integration/tests/basic_computer_games/gomoko.bas +54 -0
- data/test/integration/tests/basic_computer_games/gomoko.input +6 -0
- data/test/integration/tests/basic_computer_games/gomoko.output +66 -0
- data/test/integration/tests/basic_computer_games/guess.bas +40 -0
- data/test/integration/tests/basic_computer_games/guess.input +8 -0
- data/test/integration/tests/basic_computer_games/guess.output +37 -0
- data/test/integration/tests/basic_computer_games/gunner.bas +52 -0
- data/test/integration/tests/basic_computer_games/gunner.input +18 -0
- data/test/integration/tests/basic_computer_games/gunner.output +91 -0
- data/test/integration/tests/basic_computer_games/hamurabi.bas +119 -0
- data/test/integration/tests/basic_computer_games/hamurabi.input +7 -0
- data/test/integration/tests/basic_computer_games/hamurabi.output +51 -0
- data/test/integration/tests/basic_computer_games/hangman.bas +81 -0
- data/test/integration/tests/basic_computer_games/hangman.input +69 -0
- data/test/integration/tests/basic_computer_games/hangman.output +889 -0
- data/test/integration/tests/basic_computer_games/hello.bas +83 -0
- data/test/integration/tests/basic_computer_games/hello.input +7 -0
- data/test/integration/tests/basic_computer_games/hello.output +46 -0
- data/test/integration/tests/basic_computer_games/hexapawn.bas +174 -0
- data/test/integration/tests/basic_computer_games/hexapawn.input +38 -0
- data/test/integration/tests/basic_computer_games/hexapawn.output +521 -0
- data/test/integration/tests/basic_computer_games/hi-q.bas +135 -0
- data/test/integration/tests/basic_computer_games/hi-q.input +14 -0
- data/test/integration/tests/basic_computer_games/hi-q.output +115 -0
- data/test/integration/tests/basic_computer_games/hilo.bas +29 -0
- data/test/integration/tests/basic_computer_games/hilo.input +20 -0
- data/test/integration/tests/basic_computer_games/hilo.output +76 -0
- data/test/integration/tests/basic_computer_games/hockey.bas +210 -0
- data/test/integration/tests/basic_computer_games/hockey.input +59 -0
- data/test/integration/tests/basic_computer_games/hockey.output +243 -0
- data/test/integration/tests/basic_computer_games/horsrace.bas +130 -0
- data/test/integration/tests/basic_computer_games/horsrace.input +11 -0
- data/test/integration/tests/basic_computer_games/horsrace.output +517 -0
- data/test/integration/tests/basic_computer_games/hurkle.bas +51 -0
- data/test/integration/tests/basic_computer_games/hurkle.input +16 -0
- data/test/integration/tests/basic_computer_games/hurkle.output +81 -0
- data/test/integration/tests/basic_computer_games/kinema.bas +34 -0
- data/test/integration/tests/basic_computer_games/kinema.input +9 -0
- data/test/integration/tests/basic_computer_games/kinema.output +64 -0
- data/test/integration/tests/basic_computer_games/king.bas +268 -0
- data/test/integration/tests/basic_computer_games/king.input +7 -0
- data/test/integration/tests/basic_computer_games/king.output +57 -0
- data/test/integration/tests/basic_computer_games/lem.bas +246 -0
- data/test/integration/tests/basic_computer_games/lem.input +4 -0
- data/test/integration/tests/basic_computer_games/lem.output +68 -0
- data/test/integration/tests/basic_computer_games/letter.bas +26 -0
- data/test/integration/tests/basic_computer_games/letter.input +24 -0
- data/test/integration/tests/basic_computer_games/letter.output +123 -0
- data/test/integration/tests/basic_computer_games/life.bas +66 -0
- data/test/integration/tests/basic_computer_games/life.input +4 -0
- data/test/integration/tests/basic_computer_games/life.options +1 -0
- data/test/integration/tests/basic_computer_games/life.output +200 -0
- data/test/integration/tests/basic_computer_games/life2.bas +83 -0
- data/test/integration/tests/basic_computer_games/life2.input +17 -0
- data/test/integration/tests/basic_computer_games/life2.output +113 -0
- data/test/integration/tests/basic_computer_games/litquiz.bas +49 -0
- data/test/integration/tests/basic_computer_games/litquiz.input +4 -0
- data/test/integration/tests/basic_computer_games/litquiz.output +36 -0
- data/test/integration/tests/basic_computer_games/love.bas +34 -0
- data/test/integration/tests/basic_computer_games/love.input +1 -0
- data/test/integration/tests/basic_computer_games/love.output +67 -0
- data/test/integration/tests/basic_computer_games/lunar.bas +48 -0
- data/test/integration/tests/basic_computer_games/lunar.input +87 -0
- data/test/integration/tests/basic_computer_games/lunar.output +195 -0
- data/test/integration/tests/basic_computer_games/mastrmnd.bas +232 -0
- data/test/integration/tests/basic_computer_games/mastrmnd.input +18 -0
- data/test/integration/tests/basic_computer_games/mastrmnd.output +67 -0
- data/test/integration/tests/basic_computer_games/mathdice.bas +60 -0
- data/test/integration/tests/basic_computer_games/mathdice.input +4 -0
- data/test/integration/tests/basic_computer_games/mathdice.output +86 -0
- data/test/integration/tests/basic_computer_games/mugwump.bas +56 -0
- data/test/integration/tests/basic_computer_games/mugwump.input +16 -0
- data/test/integration/tests/basic_computer_games/mugwump.output +139 -0
- data/test/integration/tests/basic_computer_games/name.bas +25 -0
- data/test/integration/tests/basic_computer_games/name.input +2 -0
- data/test/integration/tests/basic_computer_games/name.output +22 -0
- data/test/integration/tests/basic_computer_games/nicoma.bas +34 -0
- data/test/integration/tests/basic_computer_games/nicoma.input +8 -0
- data/test/integration/tests/basic_computer_games/nicoma.output +36 -0
- data/test/integration/tests/basic_computer_games/nim.bas +156 -0
- data/test/integration/tests/basic_computer_games/nim.input +8 -0
- data/test/integration/tests/basic_computer_games/nim.output +30 -0
- data/test/integration/tests/basic_computer_games/number.bas +37 -0
- data/test/integration/tests/basic_computer_games/number.input +19 -0
- data/test/integration/tests/basic_computer_games/number.output +73 -0
- data/test/integration/tests/basic_computer_games/onecheck.bas +86 -0
- data/test/integration/tests/basic_computer_games/onecheck.input +6 -0
- data/test/integration/tests/basic_computer_games/onecheck.output +77 -0
- data/test/integration/tests/basic_computer_games/orbit.bas +96 -0
- data/test/integration/tests/basic_computer_games/orbit.input +10 -0
- data/test/integration/tests/basic_computer_games/orbit.output +113 -0
- data/test/integration/tests/basic_computer_games/pizza.bas +68 -0
- data/test/integration/tests/basic_computer_games/pizza.input +10 -0
- data/test/integration/tests/basic_computer_games/pizza.output +93 -0
- data/test/integration/tests/basic_computer_games/poetry.bas +42 -0
- data/test/integration/tests/basic_computer_games/poetry.input +0 -0
- data/test/integration/tests/basic_computer_games/poetry.options +1 -0
- data/test/integration/tests/basic_computer_games/poetry.output +50 -0
- data/test/integration/tests/basic_computer_games/poker.bas +416 -0
- data/test/integration/tests/basic_computer_games/poker.input +34 -0
- data/test/integration/tests/basic_computer_games/poker.output +197 -0
- data/test/integration/tests/basic_computer_games/queen.bas +168 -0
- data/test/integration/tests/basic_computer_games/queen.input +10 -0
- data/test/integration/tests/basic_computer_games/queen.output +133 -0
- data/test/integration/tests/basic_computer_games/reverse.bas +62 -0
- data/test/integration/tests/basic_computer_games/reverse.input +12 -0
- data/test/integration/tests/basic_computer_games/reverse.output +79 -0
- data/test/integration/tests/basic_computer_games/rocket.bas +71 -0
- data/test/integration/tests/basic_computer_games/rocket.input +42 -0
- data/test/integration/tests/basic_computer_games/rocket.output +149 -0
- data/test/integration/tests/basic_computer_games/rocksp.bas +33 -0
- data/test/integration/tests/basic_computer_games/rocksp.input +9 -0
- data/test/integration/tests/basic_computer_games/rocksp.output +69 -0
- data/test/integration/tests/basic_computer_games/roulette.bas +239 -0
- data/test/integration/tests/basic_computer_games/roulette.input +9 -0
- data/test/integration/tests/basic_computer_games/roulette.output +98 -0
- data/test/integration/tests/basic_computer_games/rusrou.bas +26 -0
- data/test/integration/tests/basic_computer_games/rusrou.input +9 -0
- data/test/integration/tests/basic_computer_games/rusrou.output +50 -0
- data/test/integration/tests/basic_computer_games/salvo.bas +329 -0
- data/test/integration/tests/basic_computer_games/salvo.input +21 -0
- data/test/integration/tests/basic_computer_games/salvo.output +49 -0
- data/test/integration/tests/basic_computer_games/sinewave.bas +17 -0
- data/test/integration/tests/basic_computer_games/sinewave.input +0 -0
- data/test/integration/tests/basic_computer_games/sinewave.output +168 -0
- data/test/integration/tests/basic_computer_games/slalom.bas +165 -0
- data/test/integration/tests/basic_computer_games/slalom.input +20 -0
- data/test/integration/tests/basic_computer_games/slalom.output +122 -0
- data/test/integration/tests/basic_computer_games/slots.bas +134 -0
- data/test/integration/tests/basic_computer_games/slots.input +2 -0
- data/test/integration/tests/basic_computer_games/slots.output +20 -0
- data/test/integration/tests/basic_computer_games/splat.bas +128 -0
- data/test/integration/tests/basic_computer_games/splat.input +9 -0
- data/test/integration/tests/basic_computer_games/splat.output +61 -0
- data/test/integration/tests/basic_computer_games/stars.bas +54 -0
- data/test/integration/tests/basic_computer_games/stars.input +15 -0
- data/test/integration/tests/basic_computer_games/stars.output +70 -0
- data/test/integration/tests/basic_computer_games/stock.bas +232 -0
- data/test/integration/tests/basic_computer_games/stock.input +30 -0
- data/test/integration/tests/basic_computer_games/stock.output +156 -0
- data/test/integration/tests/basic_computer_games/superstartrek.bas +425 -0
- data/test/integration/tests/basic_computer_games/superstartrek.input +21 -0
- data/test/integration/tests/basic_computer_games/superstartrek.output +151 -0
- data/test/integration/tests/basic_computer_games/superstartrekins.bas +127 -0
- data/test/integration/tests/basic_computer_games/superstartrekins.input +1 -0
- data/test/integration/tests/basic_computer_games/superstartrekins.output +134 -0
- data/test/integration/tests/basic_computer_games/synonym.bas +53 -0
- data/test/integration/tests/basic_computer_games/synonym.input +13 -0
- data/test/integration/tests/basic_computer_games/synonym.output +57 -0
- data/test/integration/tests/basic_computer_games/target.bas +51 -0
- data/test/integration/tests/basic_computer_games/target.input +2 -0
- data/test/integration/tests/basic_computer_games/target.output +39 -0
- data/test/integration/tests/basic_computer_games/tictac1.bas +69 -0
- data/test/integration/tests/basic_computer_games/tictac1.input +10 -0
- data/test/integration/tests/basic_computer_games/tictac1.output +49 -0
- data/test/integration/tests/basic_computer_games/tictac2.bas +114 -0
- data/test/integration/tests/basic_computer_games/tictac2.input +6 -0
- data/test/integration/tests/basic_computer_games/tictac2.output +104 -0
- data/test/integration/tests/basic_computer_games/towers.bas +125 -0
- data/test/integration/tests/basic_computer_games/towers.input +9 -0
- data/test/integration/tests/basic_computer_games/towers.output +70 -0
- data/test/integration/tests/basic_computer_games/train.bas +24 -0
- data/test/integration/tests/basic_computer_games/train.input +4 -0
- data/test/integration/tests/basic_computer_games/train.output +23 -0
- data/test/integration/tests/basic_computer_games/trap.bas +49 -0
- data/test/integration/tests/basic_computer_games/trap.input +7 -0
- data/test/integration/tests/basic_computer_games/trap.output +40 -0
- data/test/integration/tests/basic_computer_games/war.bas +68 -0
- data/test/integration/tests/basic_computer_games/war.input +11 -0
- data/test/integration/tests/basic_computer_games/war.output +54 -0
- data/test/integration/tests/basic_computer_games/weekday.bas +150 -0
- data/test/integration/tests/basic_computer_games/weekday.input +2 -0
- data/test/integration/tests/basic_computer_games/weekday.output +28 -0
- data/test/integration/tests/basic_computer_games/word.bas +65 -0
- data/test/integration/tests/basic_computer_games/word.input +6 -0
- data/test/integration/tests/basic_computer_games/word.output +0 -0
- data/test/integration/tests/fast/abs.bas +5 -0
- data/test/integration/tests/fast/abs.input +0 -0
- data/test/integration/tests/fast/abs.output +5 -0
- data/test/integration/tests/fast/add.bas +5 -0
- data/test/integration/tests/fast/add.input +0 -0
- data/test/integration/tests/fast/add.output +5 -0
- data/test/integration/tests/fast/and.bas +5 -0
- data/test/integration/tests/fast/and.input +0 -0
- data/test/integration/tests/fast/and.output +5 -0
- data/test/integration/tests/fast/array.bas +11 -0
- data/test/integration/tests/fast/array.input +0 -0
- data/test/integration/tests/fast/array.output +6 -0
- data/test/integration/tests/fast/asc.bas +1 -0
- data/test/integration/tests/fast/asc.input +0 -0
- data/test/integration/tests/fast/asc.output +1 -0
- data/test/integration/tests/fast/chr.bas +1 -0
- data/test/integration/tests/fast/chr.input +0 -0
- data/test/integration/tests/fast/chr.output +1 -0
- data/test/integration/tests/fast/cos.bas +1 -0
- data/test/integration/tests/fast/cos.input +0 -0
- data/test/integration/tests/fast/cos.output +1 -0
- data/test/integration/tests/fast/def_fn.bas +9 -0
- data/test/integration/tests/fast/def_fn.input +0 -0
- data/test/integration/tests/fast/def_fn.output +5 -0
- data/test/integration/tests/fast/divide.bas +5 -0
- data/test/integration/tests/fast/divide.input +0 -0
- data/test/integration/tests/fast/divide.output +5 -0
- data/test/integration/tests/fast/end.bas +3 -0
- data/test/integration/tests/fast/end.input +0 -0
- data/test/integration/tests/fast/end.output +1 -0
- data/test/integration/tests/fast/eq.bas +3 -0
- data/test/integration/tests/fast/eq.input +0 -0
- data/test/integration/tests/fast/eq.output +3 -0
- data/test/integration/tests/fast/exp.bas +2 -0
- data/test/integration/tests/fast/exp.input +0 -0
- data/test/integration/tests/fast/exp.output +2 -0
- data/test/integration/tests/fast/float.bas +3 -0
- data/test/integration/tests/fast/float.input +0 -0
- data/test/integration/tests/fast/float.output +2 -0
- data/test/integration/tests/fast/for_next.bas +61 -0
- data/test/integration/tests/fast/for_next.input +0 -0
- data/test/integration/tests/fast/for_next.output +46 -0
- data/test/integration/tests/fast/ge.bas +3 -0
- data/test/integration/tests/fast/ge.input +0 -0
- data/test/integration/tests/fast/ge.output +3 -0
- data/test/integration/tests/fast/gosub_return.bas +10 -0
- data/test/integration/tests/fast/gosub_return.input +0 -0
- data/test/integration/tests/fast/gosub_return.output +4 -0
- data/test/integration/tests/fast/goto.bas +3 -0
- data/test/integration/tests/fast/goto.input +0 -0
- data/test/integration/tests/fast/goto.output +1 -0
- data/test/integration/tests/fast/gt.bas +3 -0
- data/test/integration/tests/fast/gt.input +0 -0
- data/test/integration/tests/fast/gt.output +3 -0
- data/test/integration/tests/fast/if.bas +25 -0
- data/test/integration/tests/fast/if.input +0 -0
- data/test/integration/tests/fast/if.output +8 -0
- data/test/integration/tests/fast/input.bas +24 -0
- data/test/integration/tests/fast/input.input +10 -0
- data/test/integration/tests/fast/input.output +28 -0
- data/test/integration/tests/fast/int.bas +5 -0
- data/test/integration/tests/fast/int.input +0 -0
- data/test/integration/tests/fast/int.output +5 -0
- data/test/integration/tests/fast/integer_plus_string.bas +1 -0
- data/test/integration/tests/fast/integer_plus_string.input +0 -0
- data/test/integration/tests/fast/integer_plus_string.output +1 -0
- data/test/integration/tests/fast/invalid_argument.bas +1 -0
- data/test/integration/tests/fast/invalid_argument.input +0 -0
- data/test/integration/tests/fast/invalid_argument.output +1 -0
- data/test/integration/tests/fast/le.bas +3 -0
- data/test/integration/tests/fast/le.input +0 -0
- data/test/integration/tests/fast/le.output +3 -0
- data/test/integration/tests/fast/left.bas +1 -0
- data/test/integration/tests/fast/left.input +0 -0
- data/test/integration/tests/fast/left.output +1 -0
- data/test/integration/tests/fast/len.bas +2 -0
- data/test/integration/tests/fast/len.input +0 -0
- data/test/integration/tests/fast/len.output +2 -0
- data/test/integration/tests/fast/let.bas +6 -0
- data/test/integration/tests/fast/let.input +0 -0
- data/test/integration/tests/fast/let.output +4 -0
- data/test/integration/tests/fast/log.bas +1 -0
- data/test/integration/tests/fast/log.input +0 -0
- data/test/integration/tests/fast/log.output +1 -0
- data/test/integration/tests/fast/lt.bas +3 -0
- data/test/integration/tests/fast/lt.input +0 -0
- data/test/integration/tests/fast/lt.output +3 -0
- data/test/integration/tests/fast/math.output +0 -0
- data/test/integration/tests/fast/mid.bas +2 -0
- data/test/integration/tests/fast/mid.input +0 -0
- data/test/integration/tests/fast/mid.output +2 -0
- data/test/integration/tests/fast/multiply.bas +5 -0
- data/test/integration/tests/fast/multiply.input +0 -0
- data/test/integration/tests/fast/multiply.output +5 -0
- data/test/integration/tests/fast/ne.bas +3 -0
- data/test/integration/tests/fast/ne.input +0 -0
- data/test/integration/tests/fast/ne.output +3 -0
- data/test/integration/tests/fast/negate.bas +4 -0
- data/test/integration/tests/fast/negate.input +0 -0
- data/test/integration/tests/fast/negate.output +3 -0
- data/test/integration/tests/fast/not.bas +4 -0
- data/test/integration/tests/fast/not.input +0 -0
- data/test/integration/tests/fast/not.output +4 -0
- data/test/integration/tests/fast/on_goto.bas +6 -0
- data/test/integration/tests/fast/on_goto.input +0 -0
- data/test/integration/tests/fast/on_goto.output +2 -0
- data/test/integration/tests/fast/or.bas +5 -0
- data/test/integration/tests/fast/or.input +0 -0
- data/test/integration/tests/fast/or.output +5 -0
- data/test/integration/tests/fast/parentheses.bas +1 -0
- data/test/integration/tests/fast/parentheses.input +0 -0
- data/test/integration/tests/fast/parentheses.output +1 -0
- data/test/integration/tests/fast/power.bas +4 -0
- data/test/integration/tests/fast/power.input +0 -0
- data/test/integration/tests/fast/power.output +4 -0
- data/test/integration/tests/fast/print.bas +6 -0
- data/test/integration/tests/fast/print.input +0 -0
- data/test/integration/tests/fast/print.output +4 -0
- data/test/integration/tests/fast/read_data.bas +15 -0
- data/test/integration/tests/fast/read_data.input +0 -0
- data/test/integration/tests/fast/read_data.output +4 -0
- data/test/integration/tests/fast/rem.bas +1 -0
- data/test/integration/tests/fast/rem.input +0 -0
- data/test/integration/tests/fast/rem.output +0 -0
- data/test/integration/tests/fast/right.bas +1 -0
- data/test/integration/tests/fast/right.input +0 -0
- data/test/integration/tests/fast/right.output +1 -0
- data/test/integration/tests/fast/rnd.bas +5 -0
- data/test/integration/tests/fast/rnd.input +0 -0
- data/test/integration/tests/fast/rnd.output +5 -0
- data/test/integration/tests/fast/sgn.bas +5 -0
- data/test/integration/tests/fast/sgn.input +0 -0
- data/test/integration/tests/fast/sgn.output +5 -0
- data/test/integration/tests/fast/sin.bas +1 -0
- data/test/integration/tests/fast/sin.input +0 -0
- data/test/integration/tests/fast/sin.output +1 -0
- data/test/integration/tests/fast/sqr.bas +2 -0
- data/test/integration/tests/fast/sqr.input +0 -0
- data/test/integration/tests/fast/sqr.output +2 -0
- data/test/integration/tests/fast/stop.bas +3 -0
- data/test/integration/tests/fast/stop.input +0 -0
- data/test/integration/tests/fast/stop.output +2 -0
- data/test/integration/tests/fast/str.bas +3 -0
- data/test/integration/tests/fast/str.input +0 -0
- data/test/integration/tests/fast/str.output +3 -0
- data/test/integration/tests/fast/string_addition.bas +1 -0
- data/test/integration/tests/fast/string_addition.input +0 -0
- data/test/integration/tests/fast/string_addition.output +1 -0
- data/test/integration/tests/fast/string_comparisons.bas +7 -0
- data/test/integration/tests/fast/string_comparisons.input +0 -0
- data/test/integration/tests/fast/string_comparisons.output +4 -0
- data/test/integration/tests/fast/string_plus_integer.bas +1 -0
- data/test/integration/tests/fast/string_plus_integer.input +0 -0
- data/test/integration/tests/fast/string_plus_integer.output +1 -0
- data/test/integration/tests/fast/subtract.bas +5 -0
- data/test/integration/tests/fast/subtract.input +0 -0
- data/test/integration/tests/fast/subtract.output +5 -0
- data/test/integration/tests/fast/tab.bas +4 -0
- data/test/integration/tests/fast/tab.input +0 -0
- data/test/integration/tests/fast/tab.output +3 -0
- data/test/integration/tests/fast/tan.bas +1 -0
- data/test/integration/tests/fast/tan.input +0 -0
- data/test/integration/tests/fast/tan.output +1 -0
- data/test/integration/tests/fast/val.bas +3 -0
- data/test/integration/tests/fast/val.input +0 -0
- data/test/integration/tests/fast/val.output +3 -0
- data/test/spec/argument_checker_spec.rb +128 -0
- data/test/spec/basic_array_spec.rb +100 -0
- data/test/spec/basic_float_spec.rb +168 -0
- data/test/spec/basic_integer_spec.rb +270 -0
- data/test/spec/basic_numeric_spec.rb +16 -0
- data/test/spec/basic_object_spec.rb +22 -0
- data/test/spec/basic_string_spec.rb +259 -0
- data/test/spec/for_stack_spec.rb +70 -0
- data/test/spec/input_reader_spec.rb +143 -0
- data/test/spec/input_spec.rb +102 -0
- data/test/spec/line_spec.rb +18 -0
- data/test/spec/output_spec.rb +153 -0
- data/test/spec/parser_spec.rb +562 -0
- data/test/spec/program_spec.rb +45 -0
- data/test/spec/spec_helper.rb +15 -0
- data/test/spec/support/basic_numeric_helpers.rb +327 -0
- data/test/spec/support/basic_object_helpers.rb +22 -0
- data/test/spec/transcript_spec.rb +37 -0
- data/test/spec/transform_spec.rb +513 -0
- metadata +742 -0
@@ -0,0 +1,165 @@
|
|
1
|
+
10 PRINT TAB(33);"SLALOM"
|
2
|
+
20 PRINT TAB(15);"CREATIVE COMPUTING MORRISTOWN, NEW JERSEY"
|
3
|
+
30 PRINT:PRINT:PRINT
|
4
|
+
310 PRINT "HOW MANY GATES DOES THIS COURSE HAVE (1 TO 25)";
|
5
|
+
320 INPUT V
|
6
|
+
330 IF V>25 THEN 360
|
7
|
+
340 IF V<1 THEN 390
|
8
|
+
350 GOTO 1440
|
9
|
+
360 PRINT "25 IS THE LIMIT."
|
10
|
+
370 LET V=25
|
11
|
+
380 GOTO 1440
|
12
|
+
390 PRINT "TRY AGAIN,"
|
13
|
+
400 GOTO 310
|
14
|
+
410 PRINT "RATE YOURSELF AS A SKIER, (1=WORST, 3=BEST)";
|
15
|
+
420 INPUT A
|
16
|
+
430 IF A<1 THEN 460
|
17
|
+
440 IF A>3 THEN 460
|
18
|
+
450 GOTO 480
|
19
|
+
460 PRINT "THE BOUNDS ARE 1-3"
|
20
|
+
470 GOTO 410
|
21
|
+
480 PRINT"THE STARTER COUNTS DOWN...5...4...3...2...1...GO!";
|
22
|
+
490 REM
|
23
|
+
500 LET T=0
|
24
|
+
510 LET S=INT(RND(1)*(18-9)+9)
|
25
|
+
520 PRINT
|
26
|
+
525 PRINT "YOU'RE OFF!"
|
27
|
+
530 FOR O=1 TO V
|
28
|
+
540 READ Q
|
29
|
+
550 PRINT
|
30
|
+
555 PRINT "HERE COMES GATE #";STR$(O);":"
|
31
|
+
560 PRINT S;"M.P.H."
|
32
|
+
570 LET S1=S
|
33
|
+
580 PRINT "OPTION";
|
34
|
+
590 INPUT O1
|
35
|
+
600 IF O1=0 THEN 970
|
36
|
+
610 IF O1>8 THEN 1420
|
37
|
+
620 IF O1<1 THEN 1420
|
38
|
+
630 GOSUB 990
|
39
|
+
640 IF S<7 THEN 1390
|
40
|
+
650 LET T=T+(Q-S+1)
|
41
|
+
660 IF S>Q THEN 1630
|
42
|
+
670 NEXT O
|
43
|
+
680 PRINT:PRINT "YOU TOOK";(T+RND(1));"SECONDS."
|
44
|
+
690 LET M=T
|
45
|
+
700 LET M=M/V
|
46
|
+
710 IF M<1.5-(A*.1) THEN 1650
|
47
|
+
720 IF M<2.9-(A*.1) THEN 1680
|
48
|
+
730 IF M<4.4-(A*.01) THEN 1710
|
49
|
+
740 PRINT:PRINT "DO YOU WANT TO RACE AGAIN";
|
50
|
+
750 INPUT B$
|
51
|
+
760 REM
|
52
|
+
770 IF B$="NO" THEN 1740
|
53
|
+
780 IF B$="YES" THEN 480
|
54
|
+
790 PRINT "PLEASE TYPE 'YES' OR 'NO'"
|
55
|
+
800 GOTO 740
|
56
|
+
810 STOP
|
57
|
+
820 PRINT
|
58
|
+
825 PRINT "*** SLALOM: THIS IS THE 1976 WINTER OLYMPIC GIANT SLALOM. YOU ARE"
|
59
|
+
830 PRINT " THE AMERICAN TEAM'S ONLY HOPE OF A GOLD MEDAL."
|
60
|
+
840 PRINT
|
61
|
+
845 PRINT " 0 -- TYPE THIS IS YOU WANT TO SEE HOW LONG YOU'VE TAKEN."
|
62
|
+
850 PRINT " 1 -- TYPE THIS IF YOU WANT TO SPEED UP A LOT."
|
63
|
+
860 PRINT " 2 -- TYPE THIS IF YOU WANT TO SPEED UP A LITTLE."
|
64
|
+
870 PRINT " 3 -- TYPE THIS IF YOU WANT TO SPEED UP A TEENSY."
|
65
|
+
880 PRINT " 4 -- TYPE THIS IF YOU WANT TO KEEP GOING THE SAME SPEED."
|
66
|
+
890 PRINT " 5 -- TYPE THIS IF YOU WANT TO CHECK A TEENSY."
|
67
|
+
900 PRINT " 6 -- TYPE THIS IF YOU WANT TO CHECK A LITTLE."
|
68
|
+
910 PRINT " 7 -- TYPE THIS IF YOU WANT TO CHECK A LOT."
|
69
|
+
920 PRINT " 8 -- TYPE THIS IF YOU WANT TO CHEAT AND TRY TO SKIP A GATE."
|
70
|
+
930 PRINT
|
71
|
+
935 PRINT " THE PLACE TO USE THESE OPTIONS IS WHEN THE COMPUTER ASKS:"
|
72
|
+
940 PRINT
|
73
|
+
945 PRINT "OPTION?"
|
74
|
+
950 PRINT
|
75
|
+
955 PRINT " GOOD LUCK!"
|
76
|
+
957 PRINT
|
77
|
+
960 GOTO 1470
|
78
|
+
970 PRINT "YOU'VE TAKEN";(T+RND(1));"SECONDS."
|
79
|
+
980 GOTO 580
|
80
|
+
990 ON O1 GOTO 1130,1010,1170,1080,1190,1100,1150,1210
|
81
|
+
1000 STOP
|
82
|
+
1010 LET S=S+INT(RND(1)*(5-3)+3)
|
83
|
+
1020 PRINT S;"M.P.H."
|
84
|
+
1030 IF S>Q THEN 1290
|
85
|
+
1040 IF S>Q-1 THEN 1060
|
86
|
+
1050 RETURN
|
87
|
+
1060 PRINT "CLOSE ONE!"
|
88
|
+
1070 RETURN
|
89
|
+
1080 PRINT S;"M.P.H."
|
90
|
+
1090 GOTO 1030
|
91
|
+
1100 LET S=S-INT(RND(1)*(5-3)+3)
|
92
|
+
1110 PRINT S;"M.P.H."
|
93
|
+
1120 GOTO 1030
|
94
|
+
1130 LET S=S+INT(RND(1)*(10-5)+5)
|
95
|
+
1140 GOTO 1080
|
96
|
+
1150 LET S=S-INT(RND(1)*(10-5)+5)
|
97
|
+
1160 GOTO 1110
|
98
|
+
1170 LET S=S+INT(RND(1)*(4-1)+1)
|
99
|
+
1180 GOTO 1110
|
100
|
+
1190 LET S=S-INT(RND(1)*(4-1)+1)
|
101
|
+
1200 GOTO 1110
|
102
|
+
1210 PRINT "***CHEAT"
|
103
|
+
1220 IF RND(1)<.7 THEN 1260
|
104
|
+
1230 PRINT "YOU MADE IT!"
|
105
|
+
1240 LET T=T+1.5
|
106
|
+
1250 RETURN
|
107
|
+
1260 PRINT "AN OFFICIAL CAUGHT YOU!"
|
108
|
+
1270 PRINT "YOU TOOK";(T+RND(1));"SECONDS."
|
109
|
+
1280 GOTO 740
|
110
|
+
1290 IF RND(1)<((S-Q)*.1)+.2 THEN 1320
|
111
|
+
1300 PRINT "YOU WENT OVER THE NAXIMUM SPEED AND MADE IT!"
|
112
|
+
1310 RETURN
|
113
|
+
1320 PRINT "YOU WENT OVER THE MAXIMUM SPEED AND ";
|
114
|
+
1330 IF RND(1)<.5 THEN 1370
|
115
|
+
1340 PRINT "WIPED OUT!"
|
116
|
+
1350 PRINT "YOU TOOK";(T+RND(1));"SECONDS"
|
117
|
+
1360 GOTO 740
|
118
|
+
1370 PRINT "SNAGGED A FLAG!"
|
119
|
+
1380 GOTO 1350
|
120
|
+
1390 PRINT "LET'S BE REALISTIC, OK? LET'S GO BACK AND TRY AGAIN..."
|
121
|
+
1400 LET S=S1
|
122
|
+
1410 GOTO 550
|
123
|
+
1420 PRINT "WHAT?"
|
124
|
+
1430 GOTO 580
|
125
|
+
1440 PRINT
|
126
|
+
1445 PRINT "TYPE ";CHR$(34);"INS";CHR$(34);" FOR INSTRUCTIONS"
|
127
|
+
1450 PRINT "TYPE ";CHR$(34);"MAX";CHR$(34);" FOR APPROXIMATE MAXIMUM SPEEDS"
|
128
|
+
1460 PRINT "TYPE ";CHR$(34);"RUN";CHR$(34);" FOR THE BEGINNING OF THE RACE"
|
129
|
+
1470 PRINT "COMMAND--";
|
130
|
+
1480 INPUT A$
|
131
|
+
1490 REM
|
132
|
+
1500 IF A$="INS" THEN 820
|
133
|
+
1510 IF A$="MAX" THEN 1550
|
134
|
+
1520 IF A$="RUN" THEN 410
|
135
|
+
1530 PRINT CHR$(34);A$;CHR$(34);" IS AN ILLEGAL COMMAND--RETRY";
|
136
|
+
1540 GOTO 1480
|
137
|
+
1550 PRINT "GATE MAX"
|
138
|
+
1560 PRINT " # M.P.H."
|
139
|
+
1570 PRINT"----------"
|
140
|
+
1580 FOR B=1 TO V
|
141
|
+
1590 READ Q
|
142
|
+
1600 PRINT B;" ";Q
|
143
|
+
1610 NEXT B
|
144
|
+
1620 GOTO 1470
|
145
|
+
1630 LET T=T+.5
|
146
|
+
1640 GOTO 670
|
147
|
+
1650 PRINT "YOU WON A GOLD MEDAL!"
|
148
|
+
1660 LET G(1)=G(1)+1
|
149
|
+
1670 GOTO 1730
|
150
|
+
1680 PRINT "YOU WON A SILVER MEDAL"
|
151
|
+
1690 LET S(1)=S(1)+1
|
152
|
+
1700 GOTO 1730
|
153
|
+
1710 PRINT "YOU WON A BRONZE MEDAL"
|
154
|
+
1720 LET B(1)=B(1)+1
|
155
|
+
1730 GOTO 740
|
156
|
+
1740 PRINT "THANKS FOR THE RACE"
|
157
|
+
1750 IF G(1)<1 THEN 1770
|
158
|
+
1760 PRINT "GOLD MEDALS:";G(1)
|
159
|
+
1770 IF S(1)<1 THEN 1790
|
160
|
+
1780 PRINT "SILVER MEDALS:";S(1)
|
161
|
+
1790 IF B(1)<1 THEN 1830
|
162
|
+
1800 PRINT "BRONZE MEDALS:";B(1)
|
163
|
+
1810 DATA 14,18,26,29,18,25,28,32,29,20,29,29,25,21,26,29,20,21,20
|
164
|
+
1820 DATA 18,26,25,33,31,22
|
165
|
+
1830 END
|
@@ -0,0 +1,122 @@
|
|
1
|
+
SLALOM
|
2
|
+
CREATIVE COMPUTING MORRISTOWN, NEW JERSEY
|
3
|
+
|
4
|
+
|
5
|
+
|
6
|
+
HOW MANY GATES DOES THIS COURSE HAVE (1 TO 25)? 4
|
7
|
+
|
8
|
+
TYPE "INS" FOR INSTRUCTIONS
|
9
|
+
TYPE "MAX" FOR APPROXIMATE MAXIMUM SPEEDS
|
10
|
+
TYPE "RUN" FOR THE BEGINNING OF THE RACE
|
11
|
+
COMMAND--? INS
|
12
|
+
|
13
|
+
*** SLALOM: THIS IS THE 1976 WINTER OLYMPIC GIANT SLALOM. YOU ARE
|
14
|
+
THE AMERICAN TEAM'S ONLY HOPE OF A GOLD MEDAL.
|
15
|
+
|
16
|
+
0 -- TYPE THIS IS YOU WANT TO SEE HOW LONG YOU'VE TAKEN.
|
17
|
+
1 -- TYPE THIS IF YOU WANT TO SPEED UP A LOT.
|
18
|
+
2 -- TYPE THIS IF YOU WANT TO SPEED UP A LITTLE.
|
19
|
+
3 -- TYPE THIS IF YOU WANT TO SPEED UP A TEENSY.
|
20
|
+
4 -- TYPE THIS IF YOU WANT TO KEEP GOING THE SAME SPEED.
|
21
|
+
5 -- TYPE THIS IF YOU WANT TO CHECK A TEENSY.
|
22
|
+
6 -- TYPE THIS IF YOU WANT TO CHECK A LITTLE.
|
23
|
+
7 -- TYPE THIS IF YOU WANT TO CHECK A LOT.
|
24
|
+
8 -- TYPE THIS IF YOU WANT TO CHEAT AND TRY TO SKIP A GATE.
|
25
|
+
|
26
|
+
THE PLACE TO USE THESE OPTIONS IS WHEN THE COMPUTER ASKS:
|
27
|
+
|
28
|
+
OPTION?
|
29
|
+
|
30
|
+
GOOD LUCK!
|
31
|
+
|
32
|
+
COMMAND--? MAX
|
33
|
+
GATE MAX
|
34
|
+
# M.P.H.
|
35
|
+
----------
|
36
|
+
1 14
|
37
|
+
2 18
|
38
|
+
3 26
|
39
|
+
4 29
|
40
|
+
COMMAND--? RUN
|
41
|
+
RATE YOURSELF AS A SKIER, (1=WORST, 3=BEST)? 1
|
42
|
+
THE STARTER COUNTS DOWN...5...4...3...2...1...GO!
|
43
|
+
YOU'RE OFF!
|
44
|
+
|
45
|
+
HERE COMES GATE #1:
|
46
|
+
13 M.P.H.
|
47
|
+
OPTION? 5
|
48
|
+
10 M.P.H.
|
49
|
+
|
50
|
+
HERE COMES GATE #2:
|
51
|
+
10 M.P.H.
|
52
|
+
OPTION? 2
|
53
|
+
14 M.P.H.
|
54
|
+
|
55
|
+
HERE COMES GATE #3:
|
56
|
+
14 M.P.H.
|
57
|
+
OPTION? 1
|
58
|
+
21 M.P.H.
|
59
|
+
|
60
|
+
HERE COMES GATE #4:
|
61
|
+
21 M.P.H.
|
62
|
+
OPTION? 4
|
63
|
+
21 M.P.H.
|
64
|
+
|
65
|
+
YOU TOOK 41.42365 SECONDS.
|
66
|
+
|
67
|
+
DO YOU WANT TO RACE AGAIN? YES
|
68
|
+
THE STARTER COUNTS DOWN...5...4...3...2...1...GO!
|
69
|
+
YOU'RE OFF!
|
70
|
+
|
71
|
+
HERE COMES GATE #1:
|
72
|
+
14 M.P.H.
|
73
|
+
OPTION? 8
|
74
|
+
***CHEAT
|
75
|
+
AN OFFICIAL CAUGHT YOU!
|
76
|
+
YOU TOOK 0.891773 SECONDS.
|
77
|
+
|
78
|
+
DO YOU WANT TO RACE AGAIN? YES
|
79
|
+
THE STARTER COUNTS DOWN...5...4...3...2...1...GO!
|
80
|
+
YOU'RE OFF!
|
81
|
+
|
82
|
+
HERE COMES GATE #1:
|
83
|
+
17 M.P.H.
|
84
|
+
OPTION? 8
|
85
|
+
***CHEAT
|
86
|
+
AN OFFICIAL CAUGHT YOU!
|
87
|
+
YOU TOOK 0.791725 SECONDS.
|
88
|
+
|
89
|
+
DO YOU WANT TO RACE AGAIN? YES
|
90
|
+
THE STARTER COUNTS DOWN...5...4...3...2...1...GO!
|
91
|
+
YOU'RE OFF!
|
92
|
+
|
93
|
+
HERE COMES GATE #1:
|
94
|
+
13 M.P.H.
|
95
|
+
OPTION? 8
|
96
|
+
***CHEAT
|
97
|
+
AN OFFICIAL CAUGHT YOU!
|
98
|
+
YOU TOOK 0.9255966 SECONDS.
|
99
|
+
|
100
|
+
DO YOU WANT TO RACE AGAIN? YES
|
101
|
+
THE STARTER COUNTS DOWN...5...4...3...2...1...GO!
|
102
|
+
YOU'RE OFF!
|
103
|
+
|
104
|
+
HERE COMES GATE #1:
|
105
|
+
9 M.P.H.
|
106
|
+
OPTION? 1
|
107
|
+
14 M.P.H.
|
108
|
+
|
109
|
+
HERE COMES GATE #2:
|
110
|
+
14 M.P.H.
|
111
|
+
OPTION? 1
|
112
|
+
19 M.P.H.
|
113
|
+
|
114
|
+
HERE COMES GATE #3:
|
115
|
+
19 M.P.H.
|
116
|
+
OPTION? 1
|
117
|
+
28 M.P.H.
|
118
|
+
YOU WENT OVER THE MAXIMUM SPEED AND WIPED OUT!
|
119
|
+
YOU TOOK 23.97862 SECONDS
|
120
|
+
|
121
|
+
DO YOU WANT TO RACE AGAIN? NO
|
122
|
+
THANKS FOR THE RACE
|
@@ -0,0 +1,134 @@
|
|
1
|
+
10 PRINT TAB(30);"SLOTS"
|
2
|
+
20 PRINT TAB(15);"CREATIVE COMPUTING MORRISTOWN, NEW JERSEY"
|
3
|
+
30 PRINT: PRINT: PRINT
|
4
|
+
100 REM PRODUCED BY FRED MIRABELLE AND BOB HARPER ON JAN 29, 1973
|
5
|
+
110 REM IT SIMULATES THE SLOT MACHINE.
|
6
|
+
120 PRINT "YOU ARE IN THE H&M CASINO,IN FRONT OF ONE OF OUR"
|
7
|
+
130 PRINT "ONE-ARM BANDITS. BET FROM $1 TO $100."
|
8
|
+
140 PRINT "TO PULL THE ARM, PUNCH THE RETURN KEY AFTER MAKING YOUR BET."
|
9
|
+
150 LET P=0
|
10
|
+
160 PRINT: PRINT"YOUR BET";
|
11
|
+
170 INPUT M
|
12
|
+
180 IF M>100 THEN 860
|
13
|
+
190 IF M<1 THEN 880
|
14
|
+
200 M=INT(M)
|
15
|
+
210 GOSUB 1270
|
16
|
+
220 PRINT
|
17
|
+
230 LET X=INT(6*RND(1)+1)
|
18
|
+
240 LET Y=INT(6*RND(1)+1)
|
19
|
+
250 LET Z=INT(6*RND(1)+1)
|
20
|
+
260 PRINT
|
21
|
+
270 IF X=1 THEN 910
|
22
|
+
280 IF X=2 THEN 930
|
23
|
+
290 IF X=3 THEN 950
|
24
|
+
300 IF X=4 THEN 970
|
25
|
+
310 IF X=5 THEN 990
|
26
|
+
320 IF X=6 THEN 1010
|
27
|
+
330 IF Y=1 THEN 1030
|
28
|
+
340 IF Y=2 THEN 1050
|
29
|
+
350 IF Y=3 THEN 1070
|
30
|
+
360 IF Y=4 THEN 1090
|
31
|
+
370 IF Y=5 THEN 1110
|
32
|
+
380 IF Y=6 THEN 1130
|
33
|
+
390 IF Z=1 THEN 1150
|
34
|
+
400 IF Z=2 THEN 1170
|
35
|
+
410 IF Z=3 THEN 1190
|
36
|
+
420 IF Z=4 THEN 1210
|
37
|
+
430 IF Z=5 THEN 1230
|
38
|
+
440 IF Z=6 THEN 1250
|
39
|
+
450 IF X=Y THEN 600
|
40
|
+
460 IF X=Z THEN 630
|
41
|
+
470 IF Y=Z THEN 650
|
42
|
+
480 PRINT
|
43
|
+
490 PRINT "YOU LOST."
|
44
|
+
500 LET P=P-M
|
45
|
+
510 PRINT "YOUR STANDINGS ARE $"P
|
46
|
+
520 PRINT "AGAIN";
|
47
|
+
530 INPUT A$
|
48
|
+
540 IF A$="Y" THEN 160
|
49
|
+
550 PRINT
|
50
|
+
560 IF P<0 THEN 670
|
51
|
+
570 IF P=0 THEN 690
|
52
|
+
580 IF P>0 THEN 710
|
53
|
+
590 GOTO 1350
|
54
|
+
600 IF Y=Z THEN 730
|
55
|
+
610 IF Y=1 THEN 820
|
56
|
+
620 GOTO 1341
|
57
|
+
630 IF Z=1 THEN 820
|
58
|
+
640 GOTO 470
|
59
|
+
650 IF Z=1 THEN 820
|
60
|
+
660 GOTO 1341
|
61
|
+
670 PRINT "PAY UP! PLEASE LEAVE YOUR MONEY ON THE TERMINAL."
|
62
|
+
680 GOTO 1350
|
63
|
+
690 PRINT"HEY, YOU BROKE EVEN."
|
64
|
+
700 GOTO 1350
|
65
|
+
710 PRINT "COLLECT YOUR WINNINGS FROM THE H&M CASHIER."
|
66
|
+
720 GOTO 1350
|
67
|
+
730 IF Z=1 THEN 780
|
68
|
+
740 PRINT: PRINT"**TOP DOLLAR**"
|
69
|
+
750 PRINT "YOU WON!"
|
70
|
+
760 P=(((10*M)+M)+P)
|
71
|
+
770 GOTO 510
|
72
|
+
780 PRINT:PRINT"***JACKPOT***"
|
73
|
+
790 PRINT "YOU WON!"
|
74
|
+
800 P=(((100*M)+M)+P)
|
75
|
+
810 GOTO 510
|
76
|
+
820 PRINT:PRINT"*DOUBLE BAR*"
|
77
|
+
830 PRINT"YOU WON!"
|
78
|
+
840 P=(((5*M)+M)+P)
|
79
|
+
850 GOTO 510
|
80
|
+
860 PRINT"HOUSE LIMITS ARE $100"
|
81
|
+
870 GOTO 160
|
82
|
+
880 PRINT"MINIMUM BET IS $1"
|
83
|
+
890 GOTO 160
|
84
|
+
900 GOTO 220
|
85
|
+
910 PRINT"BAR";:GOSUB 1310
|
86
|
+
920 GOTO 330
|
87
|
+
930 PRINT"BELL";:GOSUB 1310
|
88
|
+
940 GOTO 330
|
89
|
+
950 PRINT"ORANGE";:GOSUB 1310
|
90
|
+
960 GOTO 330
|
91
|
+
970 PRINT"LEMON";:GOSUB 1310
|
92
|
+
980 GOTO 330
|
93
|
+
990 PRINT"PLUM";:GOSUB 1310
|
94
|
+
1000 GOTO 330
|
95
|
+
1010 PRINT"CHERRY";:GOSUB 1310
|
96
|
+
1020 GOTO 330
|
97
|
+
1030 PRINT" BAR";:GOSUB 1310
|
98
|
+
1040 GOTO 390
|
99
|
+
1050 PRINT" BELL";:GOSUB 1310
|
100
|
+
1060 GOTO 390
|
101
|
+
1070 PRINT" ORANGE";:GOSUB 1310
|
102
|
+
1080 GOTO 390
|
103
|
+
1090 PRINT" LEMON";:GOSUB 1310
|
104
|
+
1100 GOTO 390
|
105
|
+
1110 PRINT" PLUM";:GOSUB 1310
|
106
|
+
1120 GOTO 390
|
107
|
+
1130 PRINT" CHERRY";:GOSUB 1310
|
108
|
+
1140 GOTO 390
|
109
|
+
1150 PRINT" BAR"
|
110
|
+
1160 GOTO 450
|
111
|
+
1170 PRINT" BELL"
|
112
|
+
1180 GOTO 450
|
113
|
+
1190 PRINT" ORANGE"
|
114
|
+
1200 GOTO 450
|
115
|
+
1210 PRINT" LEMON"
|
116
|
+
1220 GOTO 450
|
117
|
+
1230 PRINT" PLUM"
|
118
|
+
1240 GOTO 450
|
119
|
+
1250 PRINT" CHERRY"
|
120
|
+
1260 GOTO 450
|
121
|
+
1270 FOR Q4=1 TO 10
|
122
|
+
1280 PRINT CHR$(7);
|
123
|
+
1290 NEXT Q4
|
124
|
+
1300 RETURN
|
125
|
+
1310 FOR T8=1 TO 5
|
126
|
+
1320 PRINT CHR$(7);
|
127
|
+
1330 NEXT T8
|
128
|
+
1340 RETURN
|
129
|
+
1341 PRINT: PRINT "DOUBLE!!"
|
130
|
+
1342 PRINT"YOU WON!"
|
131
|
+
1343 P=(((2*M)+M)+P)
|
132
|
+
1344 GOTO 510
|
133
|
+
1350 STOP
|
134
|
+
9999 END
|
@@ -0,0 +1,20 @@
|
|
1
|
+
SLOTS
|
2
|
+
CREATIVE COMPUTING MORRISTOWN, NEW JERSEY
|
3
|
+
|
4
|
+
|
5
|
+
|
6
|
+
YOU ARE IN THE H&M CASINO,IN FRONT OF ONE OF OUR
|
7
|
+
ONE-ARM BANDITS. BET FROM $1 TO $100.
|
8
|
+
TO PULL THE ARM, PUNCH THE RETURN KEY AFTER MAKING YOUR BET.
|
9
|
+
|
10
|
+
YOUR BET? 100
|
11
|
+
|
12
|
+
|
13
|
+
LEMON PLUM LEMON
|
14
|
+
|
15
|
+
YOU LOST.
|
16
|
+
YOUR STANDINGS ARE $-100
|
17
|
+
AGAIN? YES
|
18
|
+
|
19
|
+
PAY UP! PLEASE LEAVE YOUR MONEY ON THE TERMINAL.
|
20
|
+
Break in line 1350
|
@@ -0,0 +1,128 @@
|
|
1
|
+
10 PRINT TAB(33);"SPLAT"
|
2
|
+
20 PRINT TAB(15);"CREATIVE COMPUTING MORRISTOWN, NEW JERSEY"
|
3
|
+
40 PRINT:PRINT:PRINT
|
4
|
+
50 DIM A(42)
|
5
|
+
95 PRINT "WELCOME TO 'SPLAT' -- THE GAME THAT SIMULATES A PARACHUTE"
|
6
|
+
96 PRINT "JUMP. TRY TO OPEN YOUR CHUTE AT THE LAST POSSIBLE"
|
7
|
+
97 PRINT "MOMENT WITHOUT GOING SPLAT."
|
8
|
+
118 PRINT:PRINT:D1=0:V=0:A=0:N=0:M=0:D1=INT(9001*RND(1)+1000)
|
9
|
+
119 PRINT "SELECT YOUR OWN TERMINAL VELOCITY (YES OR NO)";:INPUT A1$
|
10
|
+
120 IF A1$="NO" GOTO 128
|
11
|
+
121 IF A1$<>"YES" THEN PRINT "YES OR NO";:INPUT A1$:GOTO 120
|
12
|
+
123 PRINT "WHAT TERMINAL VELOCITY (MI/HR)";:INPUT V1
|
13
|
+
125 V1=V1*(5280/3600):V=V1+((V1*RND(1))/20)-((V1*RND(1))/20):GOTO 135
|
14
|
+
128 V1=INT(1000*RND(1))
|
15
|
+
130 PRINT "OK. TERMINAL VELOCITY ="V1"MI/HR"
|
16
|
+
131 V1=V1*(5280/3600):V=V1+((V1*RND(1))/20)-((V1*RND(1))/20)
|
17
|
+
135 PRINT "WANT TO SELECT ACCELERATION DUE TO GRAVITY (YES OR NO)";
|
18
|
+
136 INPUT B1$
|
19
|
+
140 IF B1$="NO" GOTO 150
|
20
|
+
141 IF B1$<>"YES" THEN PRINT "YES OR NO";:INPUT B1$:GOTO 140
|
21
|
+
143 PRINT "WHAT ACCELERATION (FT/SEC/SEC)";:INPUT A2
|
22
|
+
145 A=A2+((A2*RND(1))/20)-((A2*RND(1))/20):GOTO 205
|
23
|
+
150 ON INT(1+(10*RND(1)))GOTO 151,152,153,154,155,156,157,158,159,160
|
24
|
+
151 PRINT"FINE. YOU'RE ON MERCURY. ACCELERATION=12.2 FT/SEC/SEC.":GOTO 161
|
25
|
+
152 PRINT"ALL RIGHT. YOU'RE ON VENUS. ACCELERATION=28.3 FT/SEC/SEC.":GOTO 162
|
26
|
+
153 PRINT "THEN YOU'RE ON EARTH. ACCELERATION=32.16 FT/SEC/SEC.":GOTO 163
|
27
|
+
154 PRINT"FINE. YOU'RE ON THE MOON. ACCELERATION=5.15 FT/SEC/SEC.":GOTO 164
|
28
|
+
155 PRINT"ALL RIGHT. YOU'RE ON MARS. ACCELERATION=12.5 FT/SEC/SEC.":GOTO 165
|
29
|
+
156 PRINT"THEN YOU'RE ON JUPITER. ACCELERATION=85.2 FT/SEC/SEC.":GOTO 166
|
30
|
+
157 PRINT"FINE. YOU'RE ON SATURN. ACCELERATION=37.6 FT/SEC/SEC.":GOTO 167
|
31
|
+
158 PRINT"ALL RIGHT. YOU'RE ON URANUS. ACCELERATION=33.8 FT/SEC/SEC.":GOTO 168
|
32
|
+
159 PRINT"THEN YOU'RE ON NEPTUNE. ACCELERATION=39.6 FT/SEC/SEC.":GOTO 169
|
33
|
+
160 PRINT"FINE. YOU'RE ON THE SUN. ACCELERATION=896 FT/SEC/SEC.":GOTO 170
|
34
|
+
161 A2=12.2:GOTO 145
|
35
|
+
162 A2=28.3:GOTO 145
|
36
|
+
163 A2=32.16:GOTO 145
|
37
|
+
164 A2=5.15:GOTO 145
|
38
|
+
165 A2=12.5:GOTO 145
|
39
|
+
166 A2=85.2:GOTO 145
|
40
|
+
167 A2=37.6:GOTO 145
|
41
|
+
168 A2=33.8 :GOTO 145
|
42
|
+
169 A2=39.6:GOTO 145
|
43
|
+
170 A2=896:GOTO 145
|
44
|
+
205 PRINT
|
45
|
+
206 PRINT " ALTITUDE ="D1"FT"
|
46
|
+
207 PRINT " TERM. VELOCITY ="V1"FT/SEC +/-5%"
|
47
|
+
208 PRINT " ACCELERATION ="A2"FT/SEC/SEC +/-5%"
|
48
|
+
210 PRINT "SET THE TIMER FOR YOUR FREEFALL."
|
49
|
+
211 PRINT "HOW MANY SECONDS";:INPUT T
|
50
|
+
215 PRINT "HERE WE GO."
|
51
|
+
217 PRINT
|
52
|
+
218 PRINT "TIME (SEC)","DIST TO FALL (FT)"
|
53
|
+
219 PRINT "==========","================="
|
54
|
+
300 FOR I=0 TO T STEP (T/8)
|
55
|
+
310 IF I>V/A GOTO 400
|
56
|
+
320 D=D1-((A/2)*I^2)
|
57
|
+
330 IF D<=0 GOTO 1000
|
58
|
+
340 PRINT I,D
|
59
|
+
350 NEXT I
|
60
|
+
360 GOTO 500
|
61
|
+
400 PRINT "TERMINAL VELOCITY REACHED AT T PLUS"V/A"SECONDS."
|
62
|
+
405 FOR I=I TO T STEP (T/8)
|
63
|
+
410 D=D1-((V^2/(2*A))+(V*(I-(V/A))))
|
64
|
+
420 IF D<=0 GOTO 1010
|
65
|
+
430 PRINT I,D
|
66
|
+
440 NEXT I
|
67
|
+
500 PRINT "CHUTE OPEN"
|
68
|
+
510 K=0:K1=0
|
69
|
+
550 FOR J=0 TO 42
|
70
|
+
555 IF A(J)=0 GOTO 620
|
71
|
+
560 K=K+1
|
72
|
+
570 IF D>=A(J) GOTO 600
|
73
|
+
580 K1=K1+1
|
74
|
+
600 NEXT J
|
75
|
+
610 GOTO 540
|
76
|
+
620 A(J)=D
|
77
|
+
630 IF J>2 THEN 650
|
78
|
+
635 PRINT "AMAZING!!! NOT BAD FOR YOUR ";
|
79
|
+
636 IF J=0 THEN PRINT "1ST ";
|
80
|
+
637 IF J=1 THEN PRINT "2ND ";
|
81
|
+
638 IF J=2 THEN PRINT "3RD ";
|
82
|
+
639 PRINT "SUCCESSFUL JUMP!!!":GOTO 2000
|
83
|
+
650 IF K-K1<=.1*K GOTO 700
|
84
|
+
660 IF K-K1<=.25*K GOTO 710
|
85
|
+
670 IF K-K1<=.5*K GOTO 720
|
86
|
+
680 IF K-K1<=.75*K GOTO 730
|
87
|
+
690 IF K-K1<=.9*K GOTO 740
|
88
|
+
695 GOTO 750
|
89
|
+
700 PRINT "WOW! THAT'S SOME JUMPING. OF THE"K"SUCCESSFUL JUMPS"
|
90
|
+
701 PRINT "BEFORE YOURS, ONLY"K-K1"OPENED THEIR CHUTES LOWER THAN"
|
91
|
+
702 PRINT "YOU DID."
|
92
|
+
703 GOTO 2000
|
93
|
+
710 PRINT "PRETTY GOOD! " K"SUCCESSFUL JUMPS PRECEDED YOURS AND ONLY"
|
94
|
+
711 PRINT K-K1" OF THEM GOT LOWER THAN YOU DID BEFORE THEIR CHUTES"
|
95
|
+
712 PRINT "OPENED." :GOTO 2000
|
96
|
+
720 PRINT "NOT BAD. THERE HAVE BEEN"K"SUCCESSFUL JUMPS BEFORE YOURS."
|
97
|
+
721 PRINT"YOU WERE BEATEN OUT BY"K-K1"OF THEM.":GOTO 2000
|
98
|
+
730 PRINT "CONSERVATIVE, AREN'T YOU? YOU RANKED ONLY"K-K1"IN THE"
|
99
|
+
731 PRINT K"SUCCESSFUL JUMPS BEFORE YOURS.":GOTO 2000
|
100
|
+
740 PRINT "HUMPH! DON'T YOU HAVE ANY SPORTING BLOOD? THERE WERE"
|
101
|
+
741 PRINT K"SUCCESSFUL JUMPS BEFORE YOURS AND YOU CAME IN"K1"JUMPS"
|
102
|
+
742 PRINT "BETTER THAN THE WORST. SHAPE UP!!!":GOTO 2000
|
103
|
+
750 PRINT "HEY! YOU PULLED THE RIP CORD MUCH TOO SOON. "K"SUCCESSFUL"
|
104
|
+
751 PRINT "JUMPS BEFORE YOURS AND YOU CAME IN NUMBER"K-K1"! GET WITH IT!"
|
105
|
+
752 GOTO 2000
|
106
|
+
800 PRINT "REQUIESCAT IN PACE.":GOTO 1950
|
107
|
+
801 PRINT "MAY THE ANGEL OF HEAVEN LEAD YOU INTO PARADISE.":GOTO 1950
|
108
|
+
802 PRINT "REST IN PEACE.":GOTO 1950
|
109
|
+
803 PRINT "SON-OF-A-GUN.":GOTO 1950
|
110
|
+
804 PRINT "#$%&&%!$":GOTO 1950
|
111
|
+
805 PRINT "A KICK IN THE PANTS IS A BOOST IF YOU'RE HEADED RIGHT.":GOTO 1950
|
112
|
+
806 PRINT "HMMM. SHOULD HAVE PICKED A SHORTER TIME.":GOTO 1950
|
113
|
+
807 PRINT "MUTTER. MUTTER. MUTTER.":GOTO 1950
|
114
|
+
808 PRINT "PUSHING UP DAISIES.":GOTO 1950
|
115
|
+
809 PRINT "EASY COME, EASY GO.":GOTO 1950
|
116
|
+
1000 PRINT SQR(2*D1/A),"SPLAT"
|
117
|
+
1005 ON INT(1+(10*RND(1)))GOTO 800,801,802,803,804,805,806,807,808,809
|
118
|
+
1010 PRINT (V/A)+((D1-(V^2/(2*A)))/V),"SPLAT"
|
119
|
+
1020 GOTO 1005
|
120
|
+
1950 PRINT "I'LL GIVE YOU ANOTHER CHANCE.":GOTO 2000
|
121
|
+
2000 PRINT "DO YOU WANT TO PLAY AGAIN";:INPUT Z$
|
122
|
+
2001 IF Z$="YES" GOTO 118
|
123
|
+
2002 IF Z$="NO" GOTO 2005
|
124
|
+
2003 PRINT "YES OR NO":GOTO 2000
|
125
|
+
2005 PRINT "PLEASE";:INPUT Z$:IF Z$="YES" GOTO 118
|
126
|
+
2006 IF Z$<>"NO" THEN PRINT "YES OR NO ";:GOTO 2005
|
127
|
+
2007 PRINT "SSSSSSSSSS.":PRINT:GOTO 2046
|
128
|
+
2046 END
|
@@ -0,0 +1,61 @@
|
|
1
|
+
SPLAT
|
2
|
+
CREATIVE COMPUTING MORRISTOWN, NEW JERSEY
|
3
|
+
|
4
|
+
|
5
|
+
|
6
|
+
WELCOME TO 'SPLAT' -- THE GAME THAT SIMULATES A PARACHUTE
|
7
|
+
JUMP. TRY TO OPEN YOUR CHUTE AT THE LAST POSSIBLE
|
8
|
+
MOMENT WITHOUT GOING SPLAT.
|
9
|
+
|
10
|
+
|
11
|
+
SELECT YOUR OWN TERMINAL VELOCITY (YES OR NO)? NO
|
12
|
+
OK. TERMINAL VELOCITY = 715 MI/HR
|
13
|
+
WANT TO SELECT ACCELERATION DUE TO GRAVITY (YES OR NO)? NO
|
14
|
+
ALL RIGHT. YOU'RE ON MARS. ACCELERATION=12.5 FT/SEC/SEC.
|
15
|
+
|
16
|
+
ALTITUDE = 5939 FT
|
17
|
+
TERM. VELOCITY = 1048.667 FT/SEC +/-5%
|
18
|
+
ACCELERATION = 12.5 FT/SEC/SEC +/-5%
|
19
|
+
SET THE TIMER FOR YOUR FREEFALL.
|
20
|
+
HOW MANY SECONDS? 20
|
21
|
+
HERE WE GO.
|
22
|
+
|
23
|
+
TIME (SEC) DIST TO FALL (FT)
|
24
|
+
========== =================
|
25
|
+
0 5939
|
26
|
+
2.5 5899.531
|
27
|
+
5 5781.123
|
28
|
+
7.5 5583.776
|
29
|
+
10 5307.49
|
30
|
+
12.5 4952.266
|
31
|
+
15 4518.103
|
32
|
+
17.5 4005.002
|
33
|
+
20 3412.962
|
34
|
+
CHUTE OPEN
|
35
|
+
AMAZING!!! NOT BAD FOR YOUR 1ST SUCCESSFUL JUMP!!!
|
36
|
+
DO YOU WANT TO PLAY AGAIN? YES
|
37
|
+
|
38
|
+
|
39
|
+
SELECT YOUR OWN TERMINAL VELOCITY (YES OR NO)? NO
|
40
|
+
OK. TERMINAL VELOCITY = 963 MI/HR
|
41
|
+
WANT TO SELECT ACCELERATION DUE TO GRAVITY (YES OR NO)? NO
|
42
|
+
THEN YOU'RE ON JUPITER. ACCELERATION=85.2 FT/SEC/SEC.
|
43
|
+
|
44
|
+
ALTITUDE = 9026 FT
|
45
|
+
TERM. VELOCITY = 1412.4 FT/SEC +/-5%
|
46
|
+
ACCELERATION = 85.2 FT/SEC/SEC +/-5%
|
47
|
+
SET THE TIMER FOR YOUR FREEFALL.
|
48
|
+
HOW MANY SECONDS? 60
|
49
|
+
HERE WE GO.
|
50
|
+
|
51
|
+
TIME (SEC) DIST TO FALL (FT)
|
52
|
+
========== =================
|
53
|
+
0 9026
|
54
|
+
7.5 6672.589
|
55
|
+
14.68791 SPLAT
|
56
|
+
REQUIESCAT IN PACE.
|
57
|
+
I'LL GIVE YOU ANOTHER CHANCE.
|
58
|
+
DO YOU WANT TO PLAY AGAIN? NO
|
59
|
+
PLEASE? NO
|
60
|
+
SSSSSSSSSS.
|
61
|
+
|