Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Ticket #8027: number_to_currency_test.rb

File number_to_currency_test.rb, 0.8 kB (added by jesperronn, 2 years ago)

ruby version that shows the error

Line 
1 # this ruby file shows this weird behaviour
2 "%01.2f" % 0.825
3 "%01.2f" % 1.825
4 "%01.2f" % 2.825
5 "%01.2f" % 3.825
6 "%01.2f" % 4.825
7 "%01.2f" % 5.825
8 "%01.2f" % 6.825
9 "%01.2f" % 7.825
10 "%01.2f" % 8.825
11 "%01.2f" % 9.825
12 "%01.2f" % 10.825
13 "%01.2f" % 11.825
14 "%01.2f" % 12.825
15 "%01.2f" % 13.825
16 "%01.2f" % 14.825
17 "%01.2f" % 15.825
18 "%01.2f" % 16.825
19 "%01.2f" % 17.825
20 "%01.2f" % 18.825
21 "%01.2f" % 19.825
22 "%01.2f" % 20.825
23 "%01.2f" % 21.825
24 "%01.2f" % 22.825
25 "%01.2f" % 23.825
26 "%01.2f" % 24.825
27 "%01.2f" % 25.825
28 "%01.2f" % 26.825
29 "%01.2f" % 27.825
30 "%01.2f" % 28.825
31 "%01.2f" % 29.825
32 "%01.2f" % 30.825
33 "%01.2f" % 31.825
34 "%01.2f" % 32.825
35 "%01.2f" % 33.825
36 "%01.2f" % 34.825
37 "%01.2f" % 35.825
38 "%01.2f" % 36.825
39 "%01.2f" % 37.825
40 "%01.2f" % 38.825
41 "%01.2f" % 39.825
42
43
44 #=> copenhagen.rb rails patch day
45
46
47
48