Skip to content

Commit

Permalink
minor tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
baron committed Jan 12, 2011
1 parent d4b00bf commit 5963856
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions nazna.el
Expand Up @@ -122,7 +122,8 @@
(cond
((string= i "q") (message "bye"))
((string= i "s") (nazna-skip question answer))
((if (= (floor answer) (string-to-number i))
;; answers are floored for division problems
((if (= (floor answer) (floor (string-to-number i)))
(nazna-correct)
(progn
(nazna-wrong question answer)
Expand All @@ -136,7 +137,7 @@
(let ((x (nazna-random-number))
(y (nazna-random-number))
(op (nazna-operator)))
(let ((ques (format "[%s] %s %s %s = " nazna-difficulty x op y))
(let ((ques (format "[level: %s] %s %s %s = " nazna-difficulty x op y))
(ans (nazna-solution x y op)))
(nazna-answer-problem ques ans))))

Expand Down

0 comments on commit 5963856

Please sign in to comment.