{"trustable":true,"sections":[{"title":"","value":{"format":"HTML","content":"\r\n \u003cdiv\u003e\r\n hkhv学长最近对二进制数很感兴趣,喜欢一切0和1组成的数。现在有一个十进制整数n,问你1到n之间有多少个数是只有0和1组成的类似二进制的数,输出他们的个数。\u003cbr\u003e\n\u003cdiv\u003e\n\t\u003cbr\u003e\n\u003c/div\u003e \u003c/div\u003e\r\n "}},{"title":"Input","value":{"format":"HTML","content":"\r\n \u003cdiv\u003e\r\n 输入数据包含一个数n (1 \u0026lt;\u003d n \u0026lt;\u003d10^9). \u003c/div\u003e\r\n "}},{"title":"Output","value":{"format":"HTML","content":"\r\n \u003cdiv\u003e\r\n 输出1到n中类似二进制的数的个数. \u003c/div\u003e\r\n "}},{"title":"Sample","value":{"format":"HTML","content":"\u003ctable class\u003d\u0027vjudge_sample\u0027\u003e\n\u003cthead\u003e\n \u003ctr\u003e\n \u003cth\u003eInput\u003c/th\u003e\n \u003cth\u003eOutput\u003c/th\u003e\n \u003c/tr\u003e\n\u003c/thead\u003e\n\u003ctbody\u003e\n \u003ctr\u003e\n \u003ctd\u003e\r\n \u003cpre\u003e10\u003c/pre\u003e\r\n \u003c/td\u003e\n \u003ctd\u003e\r\n \u003cpre\u003e2\u003c/pre\u003e\r\n \u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n"}},{"title":"Hint","value":{"format":"HTML","content":"\r\n \u003cpre\u003e对于n \u003d 10,1 和 10是类似二进制的数.\n\u003c/pre\u003e\r\n "}}]}