Binary Represention(LintCode 180):

Problem