英语翻译ProblemA:Divide (C/C++ recommended)A and B are two positive integers.Both ofthem are extremely large.We need you to calculate the result of A/B.Input:Input contains an integer N in the first line,and then N lines follow.Each line consists

来源:学生作业帮助网 编辑:作业帮 时间:2024/04/26 07:59:24
英语翻译ProblemA:Divide (C/C++ recommended)A and B are two positive integers.Both ofthem are extremely large.We need you to calculate the result of A/B.Input:Input contains an integer N in the first line,and then N lines follow.Each line consists

英语翻译ProblemA:Divide (C/C++ recommended)A and B are two positive integers.Both ofthem are extremely large.We need you to calculate the result of A/B.Input:Input contains an integer N in the first line,and then N lines follow.Each line consists
英语翻译
ProblemA:Divide (C/C++ recommended)
A and B are two positive integers.Both ofthem are extremely large.We need you to calculate the result of A/B.
Input:
Input contains an integer N in the first line,and then N lines follow.Each line consists of a pair of positive integers Aand B,separated by a space,one pair of integers per line.B is not zero.BothA and B have no more than 200 digits,and have no leading zeros nor leadingsigns.
Output:
For each pair of input integers A and B,youshould output the A/B in one line,and with one line of output for each line ininput.
Sample Input:
2
39 8
320703198 20516
Sample Output:
4
15631
Note:
39 / 8 = 4.875,we take only the integer part,which is 4.

英语翻译ProblemA:Divide (C/C++ recommended)A and B are two positive integers.Both ofthem are extremely large.We need you to calculate the result of A/B.Input:Input contains an integer N in the first line,and then N lines follow.Each line consists
问题A:除法(推荐用C/C++)
A和B是两个大于零的整数.这两个数值都非常大,我们需要你计算出A除以B的结果.
输入/键入:
第一行输入一个整数N
然后后面跟着N行数
每一行都是一对大于零的整数A和B,A和B之间用一个空格隔开.B不为零.每个数字长度不会超过200个字符,数字串不以零或其他符号为开头(例如"04534"或"+3425645")
输出:
每一行都是相对应整数A和B相除的结果.一行只显示一个计算结果.
样板输入:
2
39 8
320703198 20516
样板输出:
4
15631
注意:39 / 8 = 4.875,我们只取结果的整数部分,所以显示结果是4