結果
| 問題 | No.637 X: Yet Another FizzBuzz Problem |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2020-01-08 17:31:29 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 1,000 ms |
| コード長 | 343 bytes |
| 記録 | |
| コンパイル時間 | 700 ms |
| コンパイル使用メモリ | 64,384 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-11-23 02:57:54 |
| 合計ジャッジ時間 | 1,640 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 30 |
ソースコード
#include <iostream>
using namespace std;
int main(){
int ans = 0;
for(int i = 0; 5 > i; i++){
string tt;cin>>tt;
int t = stoi(tt);
if(!(t%15)){
ans += 8;
}else if(!(t%3) || !(t%5)){
ans += 4;
}else{
ans += tt.size();
}
}
cout << ans << endl;
}