summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorJongChan Choi <disjukr@naver.com>2013-09-21 05:01:47 +0900
committerJongChan Choi <disjukr@naver.com>2013-09-21 05:01:47 +0900
commit6eb210258d6c21a6634e1a459cd061a404ca78ba (patch)
tree6af0927025707fd564aee3564ee2dc11507734db
parentd3c5a723999b57774169e5cce28bebd3fc943cea (diff)
make explanation richer
-rw-r--r--brainfuck.html.markdown4
1 files changed, 3 insertions, 1 deletions
diff --git a/brainfuck.html.markdown b/brainfuck.html.markdown
index 9cc7a937..27ac6921 100644
--- a/brainfuck.html.markdown
+++ b/brainfuck.html.markdown
@@ -67,8 +67,10 @@ This program takes two numbers for input, and multiplies them.
The gist is it first reads in two inputs. Then it starts the outer loop,
conditioned on cell #1. Then it moves to cell #2, and starts the inner
loop conditioned on cell #2, incrementing cell #3. However, there comes a
-problem: at the end of the inner loop, cell #2 is zero. To solve this problem,
+problem: At the end of the inner loop, cell #2 is zero. In that case,
+inner loop won't work anymore since next time. To solve this problem,
we also increment cell #4, and then recopy cell #4 into cell #2.
+Then cell #3 is the result.
```
And that's brainfuck. Not that hard, eh? For fun, you can write your own