結果
| 問題 |
No.8043 yukicoderへようこそ!
|
| コンテスト | |
| ユーザー |
ugis_prog
|
| 提出日時 | 2019-04-01 22:08:52 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 524 bytes |
| コンパイル時間 | 1,262 ms |
| コンパイル使用メモリ | 162,544 KB |
| 実行使用メモリ | 6,820 KB |
| 最終ジャッジ日時 | 2024-11-27 02:59:22 |
| 合計ジャッジ時間 | 1,697 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 1 WA * 5 |
コンパイルメッセージ
main.cpp:4:1: warning: ISO C++ forbids declaration of ‘main’ with no type [-Wreturn-type]
4 | main(){
| ^~~~
ソースコード
#include<bits/stdc++.h>
using namespace std;
using s=string;
main(){
int A,B;
string S;
cin >> A >> B;
cin >> S;
//cout << "Hello World" << endl;
//cout << A*(A+1)/2 << endl;
//cout << A+B << " " << S << endl;
vector<string> ans(A);
for(int i=1;i<=A;i++){
if(i%15 == 0) ans[i-1] = "FizzBuzz\n";
else if(i%5 == 0) ans[i-1] = "Buzz\n";
else if(i%3 == 0) ans[i-1] = "Fizz\n";
else ans[i-1] = (to_string(i) + '\n');
}
for(auto s : ans) cout << s;
}
ugis_prog