extra tally symbol
This commit is contained in:
@@ -606,6 +606,10 @@
|
|||||||
(+= y b.height))))
|
(+= y b.height))))
|
||||||
|
|
||||||
(function pointsStr [points]
|
(function pointsStr [points]
|
||||||
(let [tallyUnit 5]
|
(let [&mut str "" tallyUnit 5 symbols ["+" "*" "\$"]]
|
||||||
(+ (* "*" (Math.floor (/ points tallyUnit)))
|
(doFor i (reverse (collect (range symbols.length)))
|
||||||
(* "+" (% points tallyUnit)))))
|
(let [scaledTallyUnit (^ tallyUnit i)
|
||||||
|
tallies (Math.floor (/ points scaledTallyUnit))]
|
||||||
|
(+= str (* (nth symbols i) tallies))
|
||||||
|
(-= points (* tallies scaledTallyUnit))))
|
||||||
|
str))
|
Reference in New Issue
Block a user