Add 2005/timwi/try.sh + format/typo checks
It only has one command. This is because I don't want to knacker my brain and I don't want to damage anyone else's brain either. Format/typo check README.md.
This commit is contained in:
1 parent
0e5422c707
commit
0f33a6784a
3 files changed
+39
-6
No files matched your search
@@ -28,12 +28,10 @@ simple 3-character fix will make it slightly less so.
|
||||
|
||||
Quite a few BF programs found on the Net expect byte-based memory, quite a few
|
||||
exceed the capacity of this interpreter, but there are many that work. Some
|
||||
small [quines][] work, some don't.
|
||||
small [quines](https://en.wikipedia.org/wiki/Quine_(computing)) work, some don't.
|
||||
|
||||
Why?
|
||||
|
||||
[quines]: https://en.wikipedia.org/wiki/Quine_(computing)
|
||||
|
||||
|
||||
## Author's remarks:
|
||||
|
||||
@@ -46,6 +44,7 @@ separated by whitespace (this will be the input to the BF program), then a `:`
|
||||
|
||||
You must not pass any command-line arguments.
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* Supports the complete set of 8 BF instructions (`+-<>[].,`).
|
||||
@@ -60,20 +59,22 @@ Use this to obfuscate your BF programs!
|
||||
|
||||
* Ignores all whitespace (newlines, spaces and tabs) in the input program.
|
||||
|
||||
|
||||
### Limitations
|
||||
|
||||
Since the program, naturally, uses ints, the calculations must not exceed the
|
||||
range of an int. (But then again, you can use the integer overflow to further
|
||||
Since the program, naturally, uses `int`s, the calculations must not exceed the
|
||||
range of an `int`. (But then again, you can use the integer overflow to further
|
||||
obfuscate your BF programs in creative ways!)
|
||||
|
||||
You are limited to 3125 input integers and 3125 instructions. If you exceed
|
||||
one of these limits, the behaviour is undefined.
|
||||
|
||||
|
||||
### Obfuscations
|
||||
|
||||
Some of the superficial obfuscations are pretty obvious: I'm using `#define`s to
|
||||
make everything look nice and lineal, and the program is merely a recursive
|
||||
`main` function with only a single `return` statement which uses nested ternary
|
||||
`main()` function with only a single `return` statement which uses nested ternary
|
||||
operators to make even the pre-processed code unreadable.
|
||||
|
||||
However, the more subtle obfuscations relate to the way the program works.
|
||||
|
||||
Executable
+26
@@ -0,0 +1,26 @@
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# try.sh - demonstrate IOCCC winner 2005/timwi
|
||||
#
|
||||
# This only does one thing and that is from the judges. This is because
|
||||
# brainfuck has too much potential to knacker the brain.
|
||||
#
|
||||
|
||||
# make sure CC is set so that when we do make CC="$CC" it isn't empty. Doing it
|
||||
# this way allows us to have the user specify a different compiler in an easy
|
||||
# way.
|
||||
if [[ -z "$CC" ]]; then
|
||||
CC="cc"
|
||||
fi
|
||||
|
||||
make CC="$CC" all >/dev/null || exit 1
|
||||
|
||||
# clear screen after compilation so that only the entry is shown
|
||||
clear
|
||||
|
||||
echo "$ (echo \"20 : ,-->+.>+.<<[>[>>+>+<<<-]>[>>+>+<<<-]>"; \
|
||||
echo "[<+>-]>[<<<+>>>-]>[-]<<<<.<-]\") | ./timwi" 1>&2
|
||||
|
||||
(echo "20 : ,-->+.>+.<<[>[>>+>+<<<-]>[>>+>+<<<-]>"; echo "[<+>-]>[<<<+>>>-]>[-]<<<<.<-]") | ./timwi
|
||||
echo 1>&2
|
||||
echo "Now please go take better care of your brain. You only get one." 1>&2
|
||||
@@ -3023,6 +3023,12 @@ how https is set up, in which case just enjoy it for what it was. But there
|
||||
might be some command line that will let it work that way.
|
||||
|
||||
|
||||
## [2005/timwi](2005/timwi/timwi.c) ([README.md](2005/timwi/README.md]))
|
||||
|
||||
Cody added [try.sh](2005/timwi/try.sh). It only has one command as he doesn't
|
||||
want to knacker his brain any more than it might or might not already be.
|
||||
|
||||
|
||||
## [2005/toledo](2005/toledo/toledo.c) ([README.md](2005/toledo/README.md))
|
||||
|
||||
Cody fixed this to compile with some versions of clang which have an additional
|
||||
|
||||
Reference in new issue
Block a user