Problem:


A : 指折り数えて / Finger Counting

問題文

肉西くんは指の数を増やしたり減らしたりできる．
肉西くんの前には n 個のまんじゅうがある．
肉西くんは指を折ってまんじゅうの個数を数えようとしている．
肉西くんの指が取れる形は折れているか折れていないかの 2 つしか無い．
肉西くんは 2 進数を理解している．
肉西くんは各指に 2 進数の桁を対応させて数を数えることが出来る．
肉西くんは対数を理解していない．
肉西くんのかわりにまんじゅうを数え上げるのに必要な指の本数の最小値を求めよ．

入力

n

制約

整数である

0 ≤ n ≤ 1018

出力

答えを 1 行に出力し，最後に改行を出力せよ．

サンプル

サンプル入力1

0

サンプル出力1

0

サンプル入力2

4

サンプル出力2

3

サンプル入力3

31

サンプル出力3

5

サンプル入力4

36028797018963968

サンプル出力4

56



Sample input:
0


Sample output:
0

Submission status: Wrong Answer

Solution code:
i = bin(int(raw_input()))
print len(str(i)[2:])

Submission status: Wrong Answer

Solution code:
i = bin(int(raw_input()))
print len(str(i)[2:])
print ""

Submission status: Wrong Answer

Solution code:
i = bin(int(raw_input()))
print str(len(str(i)[2:]))+"\n"

Submission status: Wrong Answer

Solution code:
i = bin(long(raw_input()))
print len(str(i)[2:])

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
i = bin(long(raw_input()))
print i
print len(str(i)[2:])

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python
## -*- coding:utf-8 -*-
input = raw_input()
input = bin(long(input))
i = str(input)[2:]
print len(i)

Submission status: Wrong Answer

Solution code:
input = int(raw_input())
i=0
while True:
  if(input/2 == 0):
    break
  input = input/2
  i+=1
print i+1

Submission status: Wrong Answer

Solution code:
n = int(input())
print(1 if n == 0 else len(str(bin(n))[2:]))

Submission status: Wrong Answer

Solution code:
n = int(input())
print(1 if n == 0 else len(str(bin(n))[2:]), "\n")

Submission status: Wrong Answer

Solution code:
n = int(input())
print(len(str(bin(n))[2:]))

Submission status: Wrong Answer

Solution code:
n = int(input())
print(len(str(bin(n))[2:]), "\n")

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
n = int(input())
cnt = 0
if n == 0:
    print(0)
    exit()
while 2**cnt < n :
    cnt += 1

if 2**cnt == n:
    cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
n,a=int(input()),0
while n:
    n>>=1
    a+=1
print(a)

Submission status: Accepted

Solution code:
print input().bit_length()

Submission status: Accepted

Solution code:
n = int(input())
print(0 if n == 0 else len(str(bin(n))[2:]))

Submission status: Accepted

Solution code:
n = int(input())
print(0 * (n == 0) + len(str(bin(n))[2:]) * (n != 0))

Submission status: Accepted

Solution code:
N = int(input())
ans = 0
while(N):
    N //= 2
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
# from sys import exit
# A,B,C = [int(n) for n in input().split()]
N = int(input())
# a = [int(input()) for _ in range(N)]
# S = str(input())
# L = len(S)
# T = str(input())
# exit()
# print(bin(N))
print(len(bin(N))-2 if N > 0 else 0)

Submission status: Accepted

Solution code:
n = int(input())
print(len(bin(n)) - 2 if n else 0)

Submission status: Runtime Error

Solution code:
i = bin(int(raw_input()))
print len(str(i)[2:]) + "\n"

Submission status: WA: Presentation Error

Solution code:
n = int(input())
print(0 if n == 0 else len(str(bin(n))[2:]), "\n")