結果
| 問題 |
No.188 HAPPY DAY
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2018-07-06 22:16:13 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 351 bytes |
| コンパイル時間 | 445 ms |
| コンパイル使用メモリ | 55,236 KB |
| 実行使用メモリ | 6,812 KB |
| 最終ジャッジ日時 | 2024-07-01 02:56:46 |
| 合計ジャッジ時間 | 812 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | WA * 1 |
コンパイルメッセージ
main.cpp: In function ‘int main()’:
main.cpp:13:37: warning: ‘sum’ may be used uninitialized in this function [-Wmaybe-uninitialized]
13 | sum += 1;
| ~~~~^~~~
ソースコード
#include <iostream>
using namespace std;
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
int main(void) {
int sum;
for(int i=1; i<=12; i++)
{
for(int j=1; j<=30; j++)
{
if(i == j/10 + j%10)
{
sum += 1;
}
else
{
sum += 0;
}
}
}
cout<<sum<<endl;
return 0;
}