結果
| 問題 |
No.2562 数字探しゲーム(緑以下コンver.)
|
| コンテスト | |
| ユーザー |
nonon
|
| 提出日時 | 2023-12-02 18:51:52 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 522 bytes |
| コンパイル時間 | 2,161 ms |
| コンパイル使用メモリ | 190,660 KB |
| 最終ジャッジ日時 | 2025-02-18 06:11:21 |
|
ジャッジサーバーID (参考情報) |
judge1 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 1 WA * 9 |
ソースコード
#include<bits/stdc++.h>
using namespace std;
using ll=long long;
ll T,M,d[10];
int main()
{
ios::sync_with_stdio(false);
cin.tie(nullptr);
cin>>T;
for(;T--;)
{
cin>>M;
for(int i=1;i<=9;i++)cin>>d[i];
ll ans=0;
for(int i=1;i<=9;i++)
{
for(int j=0;j<d[i];j++)
{
ans*=10;
ans+=i;
}
}
ans*=1e9;
ans+=(M-ans%M);
assert(ans<=1e18);
cout << ans << endl;
}
}
nonon