結果
問題 | No.701 ひとりしりとり |
ユーザー |
![]() |
提出日時 | 2018-08-24 19:48:19 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 165 ms / 2,000 ms |
コード長 | 1,621 bytes |
コンパイル時間 | 925 ms |
コンパイル使用メモリ | 89,332 KB |
実行使用メモリ | 11,588 KB |
最終ジャッジ日時 | 2024-06-23 04:28:55 |
合計ジャッジ時間 | 1,847 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 12 |
ソースコード
#include <iostream>#include <cassert>#include <climits>#include <bitset>#include <stack>#include <queue>#include <iomanip>#include <limits>#include <string>#include <cmath>#include <set>#include <map>#include <math.h>#include <algorithm>#include <vector>#include <string.h>using namespace std;typedef long long ll;typedef pair<ll,ll> P;long long int INF = 1e18;double Pi = 3.141592653589;long long int mod = 1000000007;// memset(a,0,sizeof(a)); →全部0にするvector<ll> G[100005];vector<P> tree[100010];priority_queue <ll> pql;priority_queue <P> pqp;//big priority queuepriority_queue <ll,vector<ll>,greater<ll>> pqls;priority_queue <P,vector<P>,greater<P>> pqps;//small priority queue//top popint dx[8]={1,0,-1,0,1,1,-1,-1};int dy[8]={0,1,0,-1,1,-1,-1,1};//↓,→,↑,←#define p(x) cout<<x<<endl;#define el cout<<endl;#define pe(x) cout<<x<<" ";#define ps(x) cout<<fixed<<setprecision(25)<<x<<endl;#define pu(x) cout<<x;#define re(i,a,b) for(i=a;i<=b;i++);#define pb push_back#define lb lower_bound#define ub upper_boundll rui(ll abc,ll bed){//aのb乗を計算するif(bed==0){return 1;}else{ll ced = rui(abc,bed/2);ced *= ced;ced %= mod;if(bed%2==1){ced*=abc; ced%=mod;}return ced;}}ll i,j,k,ii,jj;ll n,m,num;ll ans;ll a,b,c,d,e,f,g,h,w;ll x[800005],y[800005],z[900005];char s[500005];ll dp[100005][15];ll sum[100005];int main(){cin>>n;for(i=0;i<n-1;i++){a = i;cout<<"a";for(j=0;j<10;j++){s[0] = 'a';s[0] += a%10;cout<<s[0];a /= 10;}cout<<"a";el;}p("an");return 0;}