[ create a new paste ] login | about

Link: http://codepad.org/TJtZ1zID    [ raw code | output | fork ]

Ruby, pasted on Apr 11:
1
2
3
4
5
6
'1'.upto( '40' ) do |s|
        r = [s]
        r << 'aho' if s.to_i % 3 == 0 || s['3']
        r << 'wan' if s[-1] == ?0 || s[-1] == ?5
        puts r*' '
end


Output:
1
2
3 aho
4
5 wan
6 aho
7
8
9 aho
10 wan
11
12 aho
13 aho
14
15 aho wan
16
17
18 aho
19
20 wan
21 aho
22
23 aho
24 aho
25 wan
26
27 aho
28
29
30 aho wan
31 aho
32 aho
33 aho
34 aho
35 aho wan
36 aho
37 aho
38 aho
39 aho
40 wan



Create a new paste based on this one


Comments: