Colorful numbers: Difference between revisions
Content added Content deleted
m (→{{header|Ruby}}: mostly indentation) |
|||
Line 1,193: | Line 1,193: | ||
below100 = (0..100).select{|n| colorful?(n.digits)} |
below100 = (0..100).select{|n| colorful?(n.digits)} |
||
puts "The colorful numbers less than 100 are: |
puts "The colorful numbers less than 100 are:", below100.join(" "), "" |
||
puts "Largest colorful number: #{(98765432.downto(1).detect{|n| colorful?(n.digits) })}", "" |
puts "Largest colorful number: #{(98765432.downto(1).detect{|n| colorful?(n.digits) })}", "" |
||