34 Commits

Author SHA1 Message Date
Sourcery AI
71d02673a9 'Refactored by Sourcery' 2024-08-19 03:46:27 +03:00
Guido Knips
7a62098e94 Un-ignore Cargo.lock
Official cargo documentation says Cargo.lock should be
under version control for binaries (but not for libraries)

see https://doc.rust-lang.org/cargo/faq.html#why-do-binaries-have-cargolock-in-version-control-but-not-libraries
2023-08-28 21:06:35 +02:00
JoeStrout
5a886283aa MiniScript versions of Acey Ducey, Amazing, Animal, and Awari. 2023-07-10 21:24:15 -07:00
Martin Thoma
e17388d072 Use NamedTuple; Fix camelCase->snake_case 2022-04-02 11:22:40 +02:00
Martin Thoma
c500424956 Simplify Python Code
print_with_tab / print_with_whitespace is trivial with Python
string formatting and was mostly used in only 2 lines.
2022-04-02 07:32:09 +02:00
Martin Thoma
17a75813b1 Remove tests and alternative Python implementations
Ad discussed here:
https://github.com/coding-horror/basic-computer-games/issues/548#issuecomment-1081008471
2022-03-29 07:02:10 +02:00
Martin Thoma
49ae4f4872 Amazing (Python): Code Cleanup
* Make more use of a Maze class
* Create a bigger maze in the test
* Group row/col variables in Position class
* Group direction variables in an Enum
2022-03-21 14:32:48 +01:00
Martin Thoma
83b3dc402c Python: Add type annotations 2022-03-20 19:16:39 +01:00
Jeff Atwood
f40a1fc465 add Porting Notes to readme.md for each game 2022-03-18 19:50:22 -07:00
Jeff Atwood
6f6ac93d1f Merge pull request #633 from mojoaxel/js-terminal-style
Add "nice" terminal style stylesheet for javascript html
2022-03-15 23:50:18 -05:00
Jeff Atwood
43f2ec013a add 00_Alternate_Langage folder and move alternate ports there 2022-03-15 20:49:07 -07:00
Martin Thoma
0ba0307767 Python: Fix linting issues
The following Flake8 issues were fixed:

* W291
* W504

* F821
* F401
* F541

* E402
* E711
2022-03-14 13:13:20 +01:00
Alexander Wunschik
f2b3d6f2ed add terminal-stylesheet for javascript html 2022-03-13 11:23:05 +01:00
Martin Thoma
e7520d62af MAINT: Apply 'pre-commit run --all' and fix issues 2022-03-10 06:59:21 +01:00
Martin Thoma
a721c91557 Python: Add Continuous Integration for Python
There are a lot of exceptions, but it's a start.
This will ensure that no more issues get added / that issues
get fixed before the code is added
2022-03-09 21:29:06 +01:00
Martin Thoma
8cf8bab742 MAINT: Add type annotations / use functions 2022-03-07 22:00:41 +01:00
Anthony Rubick
399297b9ba Merge branch 'coding-horror:main' into rust-port-amazing 2022-03-07 09:17:35 +00:00
Martin Thoma
e64fb6795c MAINT: Apply pre-commit
Remove byte-order-marker pre-commit check as there would be
many adjustments necessary
2022-03-05 09:29:23 +01:00
AnthonyMichaelTDM
099a5be209 added exit condition
when running this as a .exe, it would close immediately after generating the maze, this is no longer the case.
2022-02-27 20:49:25 -08:00
AnthonyMichaelTDM
020fb6271f bug fix
didn't have a minimum accepted input size, and panicked during testing
2022-02-27 20:37:43 -08:00
AnthonyMichaelTDM
cd1dfd92fd readme's added 2022-02-27 20:07:18 -08:00
AnthonyMichaelTDM
c214da4713 rust port of Amazing 2022-02-23 23:58:57 -08:00
AnthonyMichaelTDM
35e0131931 rust port of Amazing 2022-02-23 23:58:17 -08:00
AnthonyMichaelTDM
af19e969a9 rust port of Amazing 2022-02-23 23:39:06 -08:00
Zev Spitz
75def2707d Add sln and csroj/vbproj files where missing 2022-01-16 08:17:31 +02:00
jcoehoorn
fbbf0bf622 Create program.vb 2022-01-09 12:37:32 -06:00
Jeff Atwood
3bb82b7cf7 Merge pull request #406 from kappa/main
02_Amazing in Perl
2022-01-04 11:09:03 -08:00
Alex Kapranoff
5409fa3daf chmod +x on the Perl script, as is done in #307 2022-01-04 00:51:54 -08:00
Alex Kapranoff
6f599f12f6 Fix the bug identified in #400 2022-01-04 00:47:34 -08:00
Alex Kapranoff
3b4b14427c 02_Amazing in Perl 2022-01-04 00:38:57 -08:00
Marc Durdin
d82a637152 chore(amazing): add note to README.md for #400 2022-01-04 16:47:32 +11:00
Marc Durdin
e8849566ba fix(amazing): guarantee exit on bottom row of maze
This issue only tends to show up on very small mazes (e.g. 2x2, 3x3). It is possible for the algorithm to never generate an exit to the maze. While the algorithm guarantees with the `Z` variable that only one exit will be generated, it does not test for the situation where we just happen to never get the right random value to open an exit on the bottom row.

The simplest resolution is just to check for this before rendering the final result (i.e. `IF Z=0`), and add an exit to a random cell on the bottom row.
2022-01-04 12:35:51 +11:00
LukasMurdock
7e3304c907 add 1-16
16:Bug
“If you elect to see all the pictures, this program has the ability of consuming well over six feet of terminal paper per run. We can only suggest recycling the paper by using the other side.”
2022-01-02 19:06:19 -05:00
Chris Reuter
d26dbf036a Removed spaces from top-level directory names.
Spaces tend to cause annoyances in a Unix-style shell environment.
This change fixes that.
2021-11-21 18:30:21 -05:00