結果

問題 No.322 Geometry Dash
ユーザー te-shte-sh
提出日時 2017-06-23 10:32:14
言語 D
(dmd 2.109.1)
結果
WA  
実行時間 -
コード長 381 bytes
コンパイル時間 1,751 ms
コンパイル使用メモリ 154,320 KB
実行使用メモリ 16,876 KB
最終ジャッジ日時 2024-06-12 20:27:56
合計ジャッジ時間 9,024 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 9 WA * 18
権限があれば一括ダウンロードができます

ソースコード

diff #

import std.algorithm, std.conv, std.range, std.stdio, std.string;

void main()
{
  auto n = readln.chomp.to!size_t;
  auto ti = readln.split.to!(int[]);
  auto di = readln.split.to!(int[]);

  auto ai = zip(ti, di).map!(a => (a[1] + 1).to!real / a[0]).array;
  auto ri = iota(n).array;
  ri.sort!((a, b) => ai[a] < ai[b]);

  writeln(ri.map!"a+1".array.to!(string[]).join(" "));
}
0