結果
問題 | No.542 1円玉と5円玉 |
ユーザー | AQUA16573837 |
提出日時 | 2018-04-05 01:05:48 |
言語 | C++11 (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 473 bytes |
コンパイル時間 | 466 ms |
コンパイル使用メモリ | 57,836 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-06-26 08:59:40 |
合計ジャッジ時間 | 1,183 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 10 |
コンパイルメッセージ
main.cpp: In function ‘void solve()’: main.cpp:20:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 20 | scanf("%d %d", &O, &F); | ~~~~~^~~~~~~~~~~~~~~~~
ソースコード
#include <stdio.h>#include <algorithm>#include <deque>#include <string>#include <iostream>using namespace std;using ll = long long;void solve();int main() {solve();#ifdef DBGwhile (true);#endif}//542void solve() {int O, F;scanf("%d %d", &O, &F);for (int five = 0; five <= F; five++)for (int one = five != 0 ? 0 : 1; one <= min(4, O); one++)printf("%d\n", five * 5 + one);for (int one = 5; one <= O; one++)printf("%d\n", F * 5 + one);}