Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
4 lines (2 sloc) 107 Bytes
POWER = (ARGV[0] || 1000).to_i
puts (2**POWER).to_s.chars.inject(0) { |sum, element| sum + element.to_i }