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,113 @@
|
|
1
|
+
ORBIT
|
2
|
+
CREATIVE COMPUTING MORRISTOWN, NEW JERSEY
|
3
|
+
|
4
|
+
|
5
|
+
|
6
|
+
SOMEWHERE ABOVE YOUR PLANET IS A ROMULAN SHIP.
|
7
|
+
|
8
|
+
THE SHIP IS IN A CONSTANT POLAR ORBIT. ITS
|
9
|
+
DISTANCE FROM THE CENTER OF YOUR PLANET IS FROM
|
10
|
+
10,000 TO 30,000 MILES AND AT ITS PRESENT VELOCITY CAN
|
11
|
+
CIRCLE YOUR PLANET ONCE EVERY 12 TO 36 HOURS.
|
12
|
+
|
13
|
+
UNFORTUNATELY, THEY ARE USING A CLOAKING DEVICE SO
|
14
|
+
YOU ARE UNABLE TO SEE THEM, BUT WITH A SPECIAL
|
15
|
+
INSTRUMENT YOU CAN TELL HOW NEAR THEIR SHIP YOUR
|
16
|
+
PHOTON BOMB EXPLODED. YOU HAVE SEVEN HOURS UNTIL THEY
|
17
|
+
HAVE BUILT UP SUFFICIENT POWER IN ORDER TO ESCAPE
|
18
|
+
YOUR PLANET'S GRAVITY.
|
19
|
+
|
20
|
+
YOUR PLANET HAS ENOUGH POWER TO FIRE ONE BOMB AN HOUR.
|
21
|
+
|
22
|
+
AT THE BEGINNING OF EACH HOUR YOU WILL BE ASKED TO GIVE AN
|
23
|
+
ANGLE (BETWEEN 0 AND 360) AND A DISTANCE IN UNITS OF
|
24
|
+
100 MILES (BETWEEN 100 AND 300), AFTER WHICH YOUR BOMB'S
|
25
|
+
DISTANCE FROM THE ENEMY SHIP WILL BE GIVEN.
|
26
|
+
|
27
|
+
AN EXPLOSION WITHIN 5,000 MILES OF THE ROMULAN SHIP
|
28
|
+
WILL DESTROY IT.
|
29
|
+
|
30
|
+
BELOW IS A DIAGRAM TO HELP YOU VISUALIZE YOUR PLIGHT.
|
31
|
+
|
32
|
+
|
33
|
+
90
|
34
|
+
0000000000000
|
35
|
+
0000000000000000000
|
36
|
+
000000 000000
|
37
|
+
00000 00000
|
38
|
+
00000 XXXXXXXXXXX 00000
|
39
|
+
00000 XXXXXXXXXXXXX 00000
|
40
|
+
0000 XXXXXXXXXXXXXXX 0000
|
41
|
+
0000 XXXXXXXXXXXXXXXXX 0000
|
42
|
+
0000 XXXXXXXXXXXXXXXXXXX 0000
|
43
|
+
180<== 00000 XXXXXXXXXXXXXXXXXXX 00000 ==>0
|
44
|
+
0000 XXXXXXXXXXXXXXXXXXX 0000
|
45
|
+
0000 XXXXXXXXXXXXXXXXX 0000
|
46
|
+
0000 XXXXXXXXXXXXXXX 0000
|
47
|
+
00000 XXXXXXXXXXXXX 00000
|
48
|
+
00000 XXXXXXXXXXX 00000
|
49
|
+
00000 00000
|
50
|
+
000000 000000
|
51
|
+
0000000000000000000
|
52
|
+
0000000000000
|
53
|
+
270
|
54
|
+
|
55
|
+
X - YOUR PLANET
|
56
|
+
O - THE ORBIT OF THE ROMULAN SHIP
|
57
|
+
|
58
|
+
ON THE ABOVE DIAGRAM, THE ROMULAN SHIP IS CIRCLING
|
59
|
+
COUNTERCLOCKWISE AROUND YOUR PLANET. DON'T FORGET THAT
|
60
|
+
WITHOUT SUFFICIENT POWER THE ROMULAN SHIP'S ALTITUDE
|
61
|
+
AND ORBITAL RATE WILL REMAIN CONSTANT.
|
62
|
+
|
63
|
+
GOOD LUCK. THE FEDERATION IS COUNTING ON YOU.
|
64
|
+
|
65
|
+
|
66
|
+
THIS IS HOUR 1 , AT WHAT ANGLE DO YOU WISH TO SEND
|
67
|
+
YOUR PHOTON BOMB? 00
|
68
|
+
HOW FAR OUT DO YOU WISH TO DETONATE IT? 200
|
69
|
+
|
70
|
+
|
71
|
+
YOUR PHOTON BOMB EXPLODED 514.0751 *10^2 MILES FROM THE
|
72
|
+
ROMULAN SHIP.
|
73
|
+
|
74
|
+
|
75
|
+
THIS IS HOUR 2 , AT WHAT ANGLE DO YOU WISH TO SEND
|
76
|
+
YOUR PHOTON BOMB? 90
|
77
|
+
HOW FAR OUT DO YOU WISH TO DETONATE IT? 200
|
78
|
+
|
79
|
+
|
80
|
+
YOUR PHOTON BOMB EXPLODED 526.9219 *10^2 MILES FROM THE
|
81
|
+
ROMULAN SHIP.
|
82
|
+
|
83
|
+
|
84
|
+
THIS IS HOUR 3 , AT WHAT ANGLE DO YOU WISH TO SEND
|
85
|
+
YOUR PHOTON BOMB? 180
|
86
|
+
HOW FAR OUT DO YOU WISH TO DETONATE IT? 270
|
87
|
+
|
88
|
+
|
89
|
+
YOUR PHOTON BOMB EXPLODED 409.8489 *10^2 MILES FROM THE
|
90
|
+
ROMULAN SHIP.
|
91
|
+
|
92
|
+
|
93
|
+
THIS IS HOUR 4 , AT WHAT ANGLE DO YOU WISH TO SEND
|
94
|
+
YOUR PHOTON BOMB? 5
|
95
|
+
HOW FAR OUT DO YOU WISH TO DETONATE IT? 270
|
96
|
+
|
97
|
+
|
98
|
+
YOUR PHOTON BOMB EXPLODED 397.977 *10^2 MILES FROM THE
|
99
|
+
ROMULAN SHIP.
|
100
|
+
|
101
|
+
|
102
|
+
THIS IS HOUR 5 , AT WHAT ANGLE DO YOU WISH TO SEND
|
103
|
+
YOUR PHOTON BOMB? 90
|
104
|
+
HOW FAR OUT DO YOU WISH TO DETONATE IT? 400
|
105
|
+
|
106
|
+
|
107
|
+
YOUR PHOTON BOMB EXPLODED 704.8363 *10^2 MILES FROM THE
|
108
|
+
ROMULAN SHIP.
|
109
|
+
|
110
|
+
|
111
|
+
THIS IS HOUR 6 , AT WHAT ANGLE DO YOU WISH TO SEND
|
112
|
+
YOUR PHOTON BOMB?
|
113
|
+
Error on line 340: No more input
|
@@ -0,0 +1,68 @@
|
|
1
|
+
5 PRINT TAB(33);"PIZZA"
|
2
|
+
10 PRINT TAB(15);"CREATIVE COMPUTING MORRISTOWN, NEW JERSEY"
|
3
|
+
15 PRINT: PRINT: PRINT
|
4
|
+
20 DIM S$(16),M$(4)
|
5
|
+
30 PRINT "PIZZA DELIVERY GAME": PRINT
|
6
|
+
50 INPUT "WHAT IS YOUR FIRST NAME";N$: PRINT
|
7
|
+
80 PRINT "HI, ";N$;". IN THIS GAME YOU ARE TO TAKE ORDERS"
|
8
|
+
90 PRINT "FOR PIZZAS. THEN YOU ARE TO TELL A DELIVERY BOY"
|
9
|
+
100 PRINT "WHERE TO DELIVER THE ORDERED PIZZAS.": PRINT: PRINT
|
10
|
+
140 FOR I=1 TO 16
|
11
|
+
150 READ S$(I)
|
12
|
+
160 NEXT I
|
13
|
+
170 FOR I=1 TO 4
|
14
|
+
180 READ M$(I)
|
15
|
+
190 NEXT I
|
16
|
+
200 DATA "A","B","C","D","E","F","G","H","I","J","K","L","M","N","O"
|
17
|
+
210 DATA "P","1","2","3","4"
|
18
|
+
230 PRINT "MAP OF THE CITY OF HYATTSVILLE": PRINT
|
19
|
+
250 PRINT " -----1-----2-----3-----4-----"
|
20
|
+
260 K=4
|
21
|
+
270 FOR I=1 TO 4
|
22
|
+
280 PRINT "-": PRINT "-": PRINT"-": PRINT "-"
|
23
|
+
320 PRINT M$(K);
|
24
|
+
330 S1=16-4*I+1
|
25
|
+
340 PRINT " ";S$(S1);" ";S$(S1+1);" ";S$(S1+2);" ";
|
26
|
+
350 PRINT S$(S1+3);" ";M$(K)
|
27
|
+
380 K=K-1
|
28
|
+
390 NEXT I
|
29
|
+
400 PRINT "-": PRINT "-": PRINT "-": PRINT "-"
|
30
|
+
440 PRINT " -----1-----2-----3-----4-----": PRINT
|
31
|
+
460 PRINT "THE OUTPUT IS A MAP OF THE HOMES WHERE"
|
32
|
+
470 PRINT "YOU ARE TO SEND PIZZAS.": PRINT
|
33
|
+
490 PRINT "YOUR JOB IS TO GIVE A TRUCK DRIVER"
|
34
|
+
500 PRINT "THE LOCATION OR COORDINATES OF THE"
|
35
|
+
510 PRINT "HOME ORDERING THE PIZZA.": PRINT
|
36
|
+
520 INPUT "DO YOU NEED MORE DIRECTIONS";A$
|
37
|
+
530 IF A$="YES" THEN 590
|
38
|
+
540 IF A$="NO" THEN 750
|
39
|
+
550 PRINT "'YES' OR 'NO' PLEASE, NOW THEN,": GOTO 520
|
40
|
+
590 PRINT: PRINT "SOMEBODY WILL ASK FOR A PIZZA TO BE"
|
41
|
+
600 PRINT "DELIVERED. THEN A DELIVERY BOY WILL"
|
42
|
+
610 PRINT "ASK YOU FOR THE LOCATION.":PRINT " EXAMPLE:"
|
43
|
+
620 PRINT "THIS IS J. PLEASE SEND A PIZZA."
|
44
|
+
640 PRINT "DRIVER TO ";N$;". WHERE DOES J LIVE?"
|
45
|
+
650 PRINT "YOUR ANSWER WOULD BE 2,3": PRINT
|
46
|
+
660 INPUT "UNDERSTAND";A$
|
47
|
+
670 IF A$="YES" THEN 690
|
48
|
+
680 PRINT "THIS JOB IS DEFINITELY TOO DIFFICULT FOR YOU. THANKS ANYWAY"
|
49
|
+
685 GOTO 999
|
50
|
+
690 PRINT "GOOD. YOU ARE NOW READY TO START TAKING ORDERS.": PRINT
|
51
|
+
700 PRINT "GOOD LUCK!!": PRINT
|
52
|
+
750 FOR I=1 TO 5
|
53
|
+
760 S=INT(RND(1)*16+1): PRINT
|
54
|
+
770 PRINT "HELLO ";N$;"'S PIZZA. THIS IS ";S$(S);".";
|
55
|
+
775 PRINT " PLEASE SEND A PIZZA."
|
56
|
+
780 PRINT " DRIVER TO ";N$;": WHERE DOES ";S$(S);" LIVE";
|
57
|
+
790 INPUT A(1),A(2)
|
58
|
+
870 T=A(1)+(A(2)-1)*4
|
59
|
+
880 IF T=S THEN 920
|
60
|
+
890 PRINT "THIS IS ";S$(T);". I DID NOT ORDER A PIZZA."
|
61
|
+
900 PRINT "I LIVE AT ";A(1);",";A(2)
|
62
|
+
910 GOTO 780
|
63
|
+
920 PRINT "HELLO "N$;". THIS IS ";S$(S);", THANKS FOR THE PIZZA."
|
64
|
+
930 NEXT I
|
65
|
+
940 PRINT: INPUT "DO YOU WANT TO DELIVER MORE PIZZAS";A$
|
66
|
+
960 IF A$="YES" THEN 750
|
67
|
+
970 PRINT: PRINT "O.K. ";N$;", SEE YOU LATER!":PRINT
|
68
|
+
999 END
|
@@ -0,0 +1,93 @@
|
|
1
|
+
PIZZA
|
2
|
+
CREATIVE COMPUTING MORRISTOWN, NEW JERSEY
|
3
|
+
|
4
|
+
|
5
|
+
|
6
|
+
PIZZA DELIVERY GAME
|
7
|
+
|
8
|
+
WHAT IS YOUR FIRST NAME? FRED
|
9
|
+
|
10
|
+
HI, FRED. IN THIS GAME YOU ARE TO TAKE ORDERS
|
11
|
+
FOR PIZZAS. THEN YOU ARE TO TELL A DELIVERY BOY
|
12
|
+
WHERE TO DELIVER THE ORDERED PIZZAS.
|
13
|
+
|
14
|
+
|
15
|
+
MAP OF THE CITY OF HYATTSVILLE
|
16
|
+
|
17
|
+
-----1-----2-----3-----4-----
|
18
|
+
-
|
19
|
+
-
|
20
|
+
-
|
21
|
+
-
|
22
|
+
4 M N O P 4
|
23
|
+
-
|
24
|
+
-
|
25
|
+
-
|
26
|
+
-
|
27
|
+
3 I J K L 3
|
28
|
+
-
|
29
|
+
-
|
30
|
+
-
|
31
|
+
-
|
32
|
+
2 E F G H 2
|
33
|
+
-
|
34
|
+
-
|
35
|
+
-
|
36
|
+
-
|
37
|
+
1 A B C D 1
|
38
|
+
-
|
39
|
+
-
|
40
|
+
-
|
41
|
+
-
|
42
|
+
-----1-----2-----3-----4-----
|
43
|
+
|
44
|
+
THE OUTPUT IS A MAP OF THE HOMES WHERE
|
45
|
+
YOU ARE TO SEND PIZZAS.
|
46
|
+
|
47
|
+
YOUR JOB IS TO GIVE A TRUCK DRIVER
|
48
|
+
THE LOCATION OR COORDINATES OF THE
|
49
|
+
HOME ORDERING THE PIZZA.
|
50
|
+
|
51
|
+
DO YOU NEED MORE DIRECTIONS? YES
|
52
|
+
|
53
|
+
SOMEBODY WILL ASK FOR A PIZZA TO BE
|
54
|
+
DELIVERED. THEN A DELIVERY BOY WILL
|
55
|
+
ASK YOU FOR THE LOCATION.
|
56
|
+
EXAMPLE:
|
57
|
+
THIS IS J. PLEASE SEND A PIZZA.
|
58
|
+
DRIVER TO FRED. WHERE DOES J LIVE?
|
59
|
+
YOUR ANSWER WOULD BE 2,3
|
60
|
+
|
61
|
+
UNDERSTAND? YES
|
62
|
+
GOOD. YOU ARE NOW READY TO START TAKING ORDERS.
|
63
|
+
|
64
|
+
GOOD LUCK!!
|
65
|
+
|
66
|
+
|
67
|
+
HELLO FRED'S PIZZA. THIS IS I. PLEASE SEND A PIZZA.
|
68
|
+
DRIVER TO FRED: WHERE DOES I LIVE? 1,3
|
69
|
+
HELLO FRED. THIS IS I, THANKS FOR THE PIZZA.
|
70
|
+
|
71
|
+
HELLO FRED'S PIZZA. THIS IS L. PLEASE SEND A PIZZA.
|
72
|
+
DRIVER TO FRED: WHERE DOES L LIVE? 4,3
|
73
|
+
HELLO FRED. THIS IS L, THANKS FOR THE PIZZA.
|
74
|
+
|
75
|
+
HELLO FRED'S PIZZA. THIS IS J. PLEASE SEND A PIZZA.
|
76
|
+
DRIVER TO FRED: WHERE DOES J LIVE? 2,3
|
77
|
+
HELLO FRED. THIS IS J, THANKS FOR THE PIZZA.
|
78
|
+
|
79
|
+
HELLO FRED'S PIZZA. THIS IS I. PLEASE SEND A PIZZA.
|
80
|
+
DRIVER TO FRED: WHERE DOES I LIVE? 1,1
|
81
|
+
THIS IS A. I DID NOT ORDER A PIZZA.
|
82
|
+
I LIVE AT 1 , 1
|
83
|
+
DRIVER TO FRED: WHERE DOES I LIVE? 1,3
|
84
|
+
HELLO FRED. THIS IS I, THANKS FOR THE PIZZA.
|
85
|
+
|
86
|
+
HELLO FRED'S PIZZA. THIS IS G. PLEASE SEND A PIZZA.
|
87
|
+
DRIVER TO FRED: WHERE DOES G LIVE? 3,2
|
88
|
+
HELLO FRED. THIS IS G, THANKS FOR THE PIZZA.
|
89
|
+
|
90
|
+
DO YOU WANT TO DELIVER MORE PIZZAS? NO
|
91
|
+
|
92
|
+
O.K. FRED, SEE YOU LATER!
|
93
|
+
|
@@ -0,0 +1,42 @@
|
|
1
|
+
10 PRINT TAB(30);"POETRY"
|
2
|
+
20 PRINT TAB(15);"CREATIVE COMPUTING MORRISTOWN, NEW JERSEY"
|
3
|
+
30 PRINT:PRINT:PRINT
|
4
|
+
90 ON I GOTO 100,101,102,103,104
|
5
|
+
100 PRINT "MIDNIGHT DREARY";:GOTO 210
|
6
|
+
101 PRINT "FIERY EYES";:GOTO 210
|
7
|
+
102 PRINT "BIRD OR FIEND";:GOTO 210
|
8
|
+
103 PRINT "THING OF EVIL";:GOTO 210
|
9
|
+
104 PRINT "PROPHET";:GOTO 210
|
10
|
+
110 ON I GOTO 111,112,113,114,115
|
11
|
+
111 PRINT "BEGUILING ME";:U=2:GOTO 210
|
12
|
+
112 PRINT "THRILLED ME";:GOTO 210
|
13
|
+
113 PRINT "STILL SITTING....";:GOTO 212
|
14
|
+
114 PRINT "NEVER FLITTING";:U=2:GOTO 210
|
15
|
+
115 PRINT "BURNED";:GOTO 210
|
16
|
+
120 ON I GOTO 121,122,123,124,125
|
17
|
+
121 PRINT "AND MY SOUL";:GOTO 210
|
18
|
+
122 PRINT "DARKNESS THERE";:GOTO 210
|
19
|
+
123 PRINT "SHALL BE LIFTED";:GOTO 210
|
20
|
+
124 PRINT "QUOTH THE RAVEN";:GOTO 210
|
21
|
+
125 IF U=0 THEN 210
|
22
|
+
126 PRINT "SIGN OF PARTING";:GOTO 210
|
23
|
+
130 ON I GOTO 131,132,133,134,135
|
24
|
+
131 PRINT "NOTHING MORE";:GOTO 210
|
25
|
+
132 PRINT "YET AGAIN";:GOTO 210
|
26
|
+
133 PRINT "SLOWLY CREEPING";:GOTO 210
|
27
|
+
134 PRINT "...EVERMORE";:GOTO 210
|
28
|
+
135 PRINT "NEVERMORE";
|
29
|
+
210 IF U=0 OR RND(1)>.19 THEN 212
|
30
|
+
211 PRINT ",";:U=2
|
31
|
+
212 IF RND(1)>.65 THEN 214
|
32
|
+
213 PRINT " ";:U=U+1:GOTO 215
|
33
|
+
214 PRINT : U=0
|
34
|
+
215 I=INT(INT(10*RND(1))/2)+1
|
35
|
+
220 J=J+1 : K=K+1
|
36
|
+
230 IF U>0 OR INT(J/2)<>J/2 THEN 240
|
37
|
+
235 PRINT " ";
|
38
|
+
240 ON J GOTO 90,110,120,130,250
|
39
|
+
250 J=0 : PRINT : IF K>20 THEN 270
|
40
|
+
260 GOTO 215
|
41
|
+
270 PRINT : U=0 : K=0 : GOTO 110
|
42
|
+
999 END
|
File without changes
|
@@ -0,0 +1 @@
|
|
1
|
+
max_output_lines: 50
|
@@ -0,0 +1,50 @@
|
|
1
|
+
POETRY
|
2
|
+
CREATIVE COMPUTING MORRISTOWN, NEW JERSEY
|
3
|
+
|
4
|
+
|
5
|
+
|
6
|
+
MIDNIGHT DREARY
|
7
|
+
THING OF EVIL NEVER FLITTING
|
8
|
+
|
9
|
+
SLOWLY CREEPING
|
10
|
+
|
11
|
+
MIDNIGHT DREARY
|
12
|
+
NEVER FLITTING
|
13
|
+
QUOTH THE RAVEN
|
14
|
+
NOTHING MORE
|
15
|
+
BIRD OR FIEND NEVER FLITTING AND MY SOUL ...EVERMORE
|
16
|
+
|
17
|
+
BIRD OR FIEND NEVER FLITTING AND MY SOUL SLOWLY CREEPING
|
18
|
+
|
19
|
+
FIERY EYES
|
20
|
+
THRILLED ME AND MY SOUL,
|
21
|
+
NOTHING MORE
|
22
|
+
|
23
|
+
BURNED
|
24
|
+
MIDNIGHT DREARY BURNED
|
25
|
+
AND MY SOUL YET AGAIN,
|
26
|
+
MIDNIGHT DREARY THRILLED ME SHALL BE LIFTED ...EVERMORE,
|
27
|
+
|
28
|
+
MIDNIGHT DREARY BURNED,
|
29
|
+
DARKNESS THERE
|
30
|
+
YET AGAIN
|
31
|
+
FIERY EYES BURNED SIGN OF PARTING
|
32
|
+
SLOWLY CREEPING
|
33
|
+
|
34
|
+
BIRD OR FIEND STILL SITTING.... AND MY SOUL
|
35
|
+
YET AGAIN
|
36
|
+
|
37
|
+
BEGUILING ME BIRD OR FIEND
|
38
|
+
NEVER FLITTING
|
39
|
+
DARKNESS THERE
|
40
|
+
NEVERMORE
|
41
|
+
THING OF EVIL BURNED, AND MY SOUL
|
42
|
+
SLOWLY CREEPING
|
43
|
+
BIRD OR FIEND
|
44
|
+
BURNED DARKNESS THERE SLOWLY CREEPING,
|
45
|
+
THING OF EVIL BURNED AND MY SOUL YET AGAIN
|
46
|
+
BIRD OR FIEND THRILLED ME SIGN OF PARTING YET AGAIN
|
47
|
+
|
48
|
+
STILL SITTING.... THING OF EVIL BEGUILING ME,
|
49
|
+
SHALL BE LIFTED
|
50
|
+
NEVERMOREError on line 214: Maximum output lines reached
|