結果
| 問題 | No.3069 Invisible Speedrun |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-03-21 22:49:41 |
| 言語 | D (dmd 2.112.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 638 bytes |
| 記録 | |
| コンパイル時間 | 3,421 ms |
| コンパイル使用メモリ | 190,520 KB |
| 実行使用メモリ | 9,304 KB |
| 平均クエリ数 | 2.00 |
| 最終ジャッジ日時 | 2026-07-07 15:56:55 |
| 合計ジャッジ時間 | 6,785 ms |
|
ジャッジサーバーID (参考情報) |
judge3_1 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 1 |
| other | WA * 80 |
ソースコード
import std;
void main () {
int N = readln.chomp.to!int;
// ジグザグで通りそう
auto command = new byte[](2 * N);
foreach (i; 0 .. N) {
command[2 * i] = 'R';
command[2 * i + 1] = 'D';
}
writeln(command);
foreach (c; command) {
writeln(c.to!char);
stdout.flush;
int v = readln.chomp.to!int;
if (v == 1) return;
if (v == -1) return;
}
}
void read (T...) (string S, ref T args) {
import std.conv : to;
import std.array : split;
auto buf = S.split;
foreach (i, ref arg; args) {
arg = buf[i].to!(typeof(arg));
}
}