2017 ACM-ICPC 亚洲区(西安赛区)网络赛 C
2017-09-16 22:51
429 查看
Define the function S(x)S(x)S(x)
for xxx
is a positive integer. S(x)S(x)S(x)
equals to the sum of all digit of the decimal expression of
xxx. Please find
a positive integer kkk
that S(k∗x)%233=0S(k*x)\%233=0S(k∗x)%233=0.
indicates the number of test cases (T≤100T \le 100T≤100).
Then Each line has a single integer x(1≤x≤1000000)x(1 \le x \le 1000000)x(1≤x≤1000000)
indicates i-th test case.
If there are more than one answer, output anyone is ok.
题目说的是输出任何一个答案都行
那就找一个不超2000位,然后每个数都符合条件的一个答案就行了
for xxx
is a positive integer. S(x)S(x)S(x)
equals to the sum of all digit of the decimal expression of
xxx. Please find
a positive integer kkk
that S(k∗x)%233=0S(k*x)\%233=0S(k∗x)%233=0.
Input Format
First line an integer TTT,indicates the number of test cases (T≤100T \le 100T≤100).
Then Each line has a single integer x(1≤x≤1000000)x(1 \le x \le 1000000)x(1≤x≤1000000)
indicates i-th test case.
Output Format
For each test case, print an integer in a single line indicates the answer. The length of the answer should not exceed200020002000.If there are more than one answer, output anyone is ok.
样例输入
1 1
样例输出
89999999999999999999999999
题目说的是输出任何一个答案都行
那就找一个不超2000位,然后每个数都符合条件的一个答案就行了
#include<iostream> #include<cstdio> #include<cstring> #include<algorithm> #include<cmath> #include<queue> #include<map> #include<cstdlib> #include<string> #include<set> #include<stack> #define mod 1000000007 using namespace std; int main() { int T; int x; scanf("%d",&T); while(T--){ scanf("%d",&x); for(int i=0;i<233;i++){ printf("10000000"); } printf("\n"); } return 0; }
相关文章推荐
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 B. Coin
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 B. Coin
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 - Coin(二项式展开)
- 计蒜客 17116 Sum(2017 ACM-ICPC 亚洲区(西安赛区)网络赛 C)
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 Coin 矩阵快速幂
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 Maximum Flow
- 【推导】计蒜客17119 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 F. Trig Function
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 E. Maximum Flow
- 计蒜客17116 Sum 找规律 2017 ACM-ICPC 亚洲区(西安赛区)网络赛
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 C. Sum
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 F. Trig Function cos(nx)
- 计蒜客-2017 ACM-ICPC 亚洲区(西安赛区)网络赛E题Maximum Flow(网络流打表找规律)
- C. Sum 数学/规律 2017 ACM-ICPC 亚洲区(西安赛区)网络赛
- Coin (2017 ACM-ICPC 亚洲区(西安赛区)网络赛B题)
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 F. Trig Function(切比雪夫多项式)
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 F. Trig Function cos(nx)
- 【2017 ACM-ICPC 亚洲区(西安赛区)网络赛】 B. Coin
- 计蒜客 17118 Maximum Flow(2017 ACM-ICPC 亚洲区(西安赛区)网络赛 E)
- 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 C. Sum
- 【Trie】【kd-tree】计蒜客17122 2017 ACM-ICPC 亚洲区(西安赛区)网络赛 I. Barty's Computer