結果
| 問題 |
No.232 めぐるはめぐる (2)
|
| コンテスト | |
| ユーザー |
h_noson
|
| 提出日時 | 2016-02-20 20:37:34 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 980 bytes |
| コンパイル時間 | 654 ms |
| コンパイル使用メモリ | 59,396 KB |
| 実行使用メモリ | 6,948 KB |
| 最終ジャッジ日時 | 2024-09-22 12:29:49 |
| 合計ジャッジ時間 | 2,807 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 19 WA * 3 |
ソースコード
#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
#define RREP(i,s,e) for (i = e-1; i >= s; i--)
#define rrep(i,n) RREP(i,0,n)
#define REP(i,s,e) for (i = s; i < e; i++)
#define rep(i,n) REP(i,0,n)
#define INF 1e8
typedef long long ll;
int main() {
int t, a, b, x, y;
cin >> t >> a >> b;
if (t < max(a,b)) {
cout << "NO" << endl;
return 0;
}
cout << "YES" << endl;
x = y = 0;
while (t > 0) {
if (t > b) {
if (y < a) {
cout << "^" << endl;
y++;
}
else {
cout << "v" << endl;
y--;
}
}
else {
if (y < a) {
cout << "^";
y++;
}
else if (y > a) {
cout << "v";
y--;
}
cout << ">" << endl;
x++;
}
t--;
}
return 0;
}
h_noson