As we know, Big Number is always troublesome. But it's really important in our ACM. And today, your task is to write a program to calculate A mod B.

To make the problem easier, I promise that B will be smaller than 100000.

Is it too hard? No, I work it out in 10 minutes, and my program contains less than 25 lines.

InputThe input contains several test cases. Each test case consists of two positive integers A and B. The length of A will not exceed 1000, and B will be smaller than 100000. Process to the end of file. 
OutputFor each test case, you have to ouput the result of A mod B. 
Sample Input

2 3
12 7
152455856554521 3250

Sample Output

2
5
1521

Big Number HDU - 1212的更多相关文章

  1. 线段树 逆序对 Minimum Inversion Number HDU - 1394 Laptop

    Minimum Inversion Number HDU - 1394 求最小反转数,就是求最少的逆序对. 逆序对怎么求,就是先把所有的数都初始化为0,然后按照顺序放入数字,放入数字前查询从这个数往后 ...

  2. hdu 1212 Big Number

    题目连接 http://acm.hdu.edu.cn/showproblem.php?pid=1212 Big Number Description As we know, Big Number is ...

  3. HDU 1212 Big Number(C++ 大数取模)(java 大数类运用)

    Big Number 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1212 ——每天在线,欢迎留言谈论. 题目大意: 给你两个数 n1,n2.其中n1 ...

  4. HDU 1212 Big Number 大数模小数

    http://acm.hdu.edu.cn/showproblem.php?pid=1212 题目大意: 给你一个长度不超过1000的大数A,还有一个不超过100000的B,让你快速求A % B. 什 ...

  5. hdu 1212 Big Number(大数取模)

    Problem Description As we know, Big Number is always troublesome. But it's really important in our A ...

  6. 题解报告:hdu 1212 Big Number(大数取模+同余定理)

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1212 Problem Description As we know, Big Number is al ...

  7. BestCoder13 1001.Beautiful Palindrome Number(hdu 5062) 解题报告

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=5062 题目意思:给出 N,找出 1 - 10^N 中满足 Beautiful Palindrome N ...

  8. Minimum Inversion Number~hdu 1394

    The inversion number of a given number sequence a1, a2, ..., an is the number of pairs (ai, aj) that ...

  9. ACM-ICPC 2016 大连赛区现场赛 K. Guess the number && HDU 5981(思维+DP)

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=5981 题意:A在[L, R]之间随机选取一个数X,之后B来猜这个数,如果猜的数比X小,那么A就告诉B猜 ...

随机推荐

  1. window操作命令

    netstat -ano 查看所有端口 netstat -ano|findstr "8005"  查看指定端口

  2. 初始化workbook时可能忽略的问题

    正常情况下解析excel 先初始化workbook,使用文件名称后缀来初始化的. 一般情况下 这种是没有问题的,但是当遇到如果是07版本的 xlsx结尾的文件 改了后缀 为xls后 解析就会发生异常 ...

  3. on windows in superset sql lab error "module object has no attribute sigalrm"

    改下  utils.py   文件 It works after doing the following change (sorry for the massed up alignment, prob ...

  4. HDU6438 Buy and Resell 2018CCPC网络赛 -低买高卖-贪心经典题

    目录 Catalog Solution: (有任何问题欢迎留言或私聊 && 欢迎交流讨论哦 Catalog Problem:Portal传送门  原题目描述在最下面.  出过很多次:5 ...

  5. spring注解方式配置以及spring4的泛型注入 (4)

    目录 一.@Controller 注解控制层(action) 二.@Service 注解服务层 三.@Repository 持久层 四.spring4的泛型注入测试 1 创建两个实体User和Role ...

  6. 微信-小程序-开发文档-服务端-模板消息:templateMessage.getTemplateList

    ylbtech-微信-小程序-开发文档-服务端-模板消息:templateMessage.getTemplateList 1.返回顶部 1. templateMessage.getTemplateLi ...

  7. org.mybatis总是认不出来的原因,pom.xml中有

    idea打开maven project,然后就华丽丽的看见下载失败,怎么刷新都没有用. 请按以下步骤完成即可: https://blog.csdn.net/ZhengYanFeng1989/artic ...

  8. C#枚举转化示例大全,数字或字符串转枚举

    本文重点举例说明C#枚举的用法,数字转化为枚举.枚举转化为数字及其枚举数值的判断,以下是具体的示例: 先举两个简单的例子,然后再详细的举例说明: 字符串转换成枚举:DayOfWeek week=(Da ...

  9. Caused by: java.io.FileNotFoundException: class path resource [com/cxy/springboot/mapping/] cannot be resolved to URL because it does not exist

    java.lang.IllegalStateException: Failed to load ApplicationContext at org.springframework.test.conte ...

  10. C9 vs 三星

    我还是更喜欢 C9, 可惜当年的牛B人物 LemonNation 不在了,C9 赢 三星 一局的机会都没有了. 伟大的 LemonNation ,软件工程学硕士, 2014年,LemonNation ...