pascal AC

var
m:longint;n:integer; a:array[1..10] of longint=(2,4,8,16,32,64,128,256,512,1024);
begin readln(m,n);writeln(m-((m+a[n]-1) div a[n]));end.

测试数据 #0: Accepted, time = 0 ms, mem = 808 KiB, score = 20
测试数据 #1: Accepted, time = 0 ms, mem = 808 KiB, score = 20
测试数据 #2: Accepted, time = 0 ms, mem = 812 KiB, score = 20
测试数据 #3: Accepted, time = 0 ms, mem = 808 KiB, score = 20
测试数据 #4: Accepted, time = 0 ms, mem = 812 KiB, score = 20
Accepted, time = 0 ms, mem = 812 KiB, score = 100

2 条评论

  • @ 2017-01-21 20:45:29

    pascal没有移位?!

  • @ 2017-01-20 21:22:30

    请不要在讨论区发布通过的代码。
    您可以将自己的代码和做题心得发布到**查看与发表题解**中,例如:https://vijos.org/p/1785/solution

  • 1

信息

ID
1785
难度
2
分类
模拟 点击显示
标签
(无)
递交数
918
已通过
557
通过率
61%
被复制
2
上传者