結果

問題 No.1869 Doubling?
ユーザー shobonvipshobonvip
提出日時 2022-03-11 22:38:44
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 83 ms / 2,000 ms
コード長 130 bytes
コンパイル時間 453 ms
コンパイル使用メモリ 87,088 KB
実行使用メモリ 71,660 KB
最終ジャッジ日時 2023-10-14 07:54:40
合計ジャッジ時間 5,902 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 76 ms
71,192 KB
testcase_01 AC 77 ms
71,568 KB
testcase_02 AC 77 ms
71,404 KB
testcase_03 AC 77 ms
71,168 KB
testcase_04 AC 79 ms
71,492 KB
testcase_05 AC 78 ms
71,400 KB
testcase_06 AC 77 ms
71,044 KB
testcase_07 AC 78 ms
71,188 KB
testcase_08 AC 77 ms
71,392 KB
testcase_09 AC 76 ms
71,552 KB
testcase_10 AC 76 ms
71,244 KB
testcase_11 AC 77 ms
71,168 KB
testcase_12 AC 78 ms
71,164 KB
testcase_13 AC 77 ms
71,136 KB
testcase_14 AC 78 ms
71,396 KB
testcase_15 AC 76 ms
71,344 KB
testcase_16 AC 77 ms
71,044 KB
testcase_17 AC 75 ms
71,240 KB
testcase_18 AC 77 ms
71,348 KB
testcase_19 AC 76 ms
71,244 KB
testcase_20 AC 77 ms
71,360 KB
testcase_21 AC 75 ms
71,304 KB
testcase_22 AC 78 ms
71,660 KB
testcase_23 AC 79 ms
71,240 KB
testcase_24 AC 77 ms
71,240 KB
testcase_25 AC 78 ms
71,044 KB
testcase_26 AC 79 ms
71,364 KB
testcase_27 AC 76 ms
71,524 KB
testcase_28 AC 77 ms
71,256 KB
testcase_29 AC 77 ms
71,260 KB
testcase_30 AC 76 ms
71,040 KB
testcase_31 AC 80 ms
71,240 KB
testcase_32 AC 83 ms
71,256 KB
testcase_33 AC 79 ms
71,436 KB
testcase_34 AC 77 ms
71,136 KB
testcase_35 AC 77 ms
71,320 KB
testcase_36 AC 76 ms
71,336 KB
testcase_37 AC 77 ms
71,040 KB
testcase_38 AC 76 ms
71,168 KB
testcase_39 AC 77 ms
71,440 KB
testcase_40 AC 78 ms
71,140 KB
testcase_41 AC 77 ms
71,256 KB
testcase_42 AC 78 ms
71,548 KB
testcase_43 AC 78 ms
71,464 KB
testcase_44 AC 77 ms
71,336 KB
testcase_45 AC 76 ms
71,188 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n,m=map(int,input().split())
t=m;ans=0;u=0
while 1<t<=m:
	ans+=t
	t=(t+1)>>1
	u+=1
if u+1<=n:
	print(ans+n-u)
else:
	print(2**n-1)
0