結果

問題 No.481 1から10
ユーザー Marty_9800
提出日時 2018-09-13 22:11:53
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 252 bytes
コンパイル時間 422 ms
コンパイル使用メモリ 55,776 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-07-01 04:30:39
合計ジャッジ時間 992 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 8
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
using namespace std;
int main() {
	int N;
	int i;
	for (i = 1; i <= 9; i++)
	{
		cin >> N;
		if (N != i) {
			break;
		}
	}
	if (i == 10) {
		cout << 10 << endl;
	}
	else {
		cout << N - 1 << endl;
	}
	return 0;
}
0