牛客多校第五场 A digits 2 签到

题意:

给定一个n,输出一个数,要求这个数所有位之和整除n,并且这个数也整除n,并且位数不许多于1e4

题解:

把这个数n输出n遍。

#include<iostream>
using namespace std;
int main(){
    int t;
    scanf("%d",&t);
    while(t--){
        int q;
        scanf("%d",&q);
        for(int i=1;i<=q;i++)printf("%d",q);
        printf("\n");
    }
    return 0;
}

猜你喜欢

转载自www.cnblogs.com/isakovsky/p/11285133.html