Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
10 lines (7 sloc) 121 Bytes
#!/usr/bin/ruby
def hexdec(hex)
dec = hex.to_i(16)
return dec
end
hex = ARGV[0] || STDIN.gets.chomp
puts hexdec(hex)