Last active
December 17, 2015 14:29
-
-
Save msuarz/5625166 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fs = require 'fs' | |
process.stdin.resume() | |
rawData = fs.readSync process.stdin.fd, 100, 0, 'utf8' | |
@lines = rawData[0].split '\r\n' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
re_bin = (x) -> console.log parseInt x | |
.toString(2) | |
.split('') | |
.reverse() | |
.join('') | |
, 2 | |
{ lines } = require './read_input_file' | |
re_bin Number line for line in lines | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment