結果

問題 No.322 Geometry Dash
ユーザー asi1024asi1024
提出日時 2015-12-15 13:36:25
言語 C++11
(gcc 11.4.0)
結果
AC  
実行時間 95 ms / 2,000 ms
コード長 524 bytes
コンパイル時間 1,471 ms
コンパイル使用メモリ 168,252 KB
実行使用メモリ 9,600 KB
最終ジャッジ日時 2024-04-26 04:55:22
合計ジャッジ時間 7,232 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
6,816 KB
testcase_01 AC 1 ms
6,944 KB
testcase_02 AC 1 ms
6,944 KB
testcase_03 AC 1 ms
6,944 KB
testcase_04 AC 76 ms
9,516 KB
testcase_05 AC 82 ms
9,536 KB
testcase_06 AC 83 ms
9,472 KB
testcase_07 AC 85 ms
9,472 KB
testcase_08 AC 88 ms
9,600 KB
testcase_09 AC 78 ms
9,540 KB
testcase_10 AC 80 ms
9,568 KB
testcase_11 AC 85 ms
9,424 KB
testcase_12 AC 85 ms
9,404 KB
testcase_13 AC 88 ms
9,472 KB
testcase_14 AC 83 ms
9,404 KB
testcase_15 AC 85 ms
9,568 KB
testcase_16 AC 85 ms
9,600 KB
testcase_17 AC 89 ms
9,540 KB
testcase_18 AC 88 ms
9,544 KB
testcase_19 AC 85 ms
9,504 KB
testcase_20 AC 88 ms
9,472 KB
testcase_21 AC 86 ms
9,600 KB
testcase_22 AC 90 ms
9,472 KB
testcase_23 AC 94 ms
9,600 KB
testcase_24 AC 88 ms
9,472 KB
testcase_25 AC 88 ms
9,472 KB
testcase_26 AC 90 ms
9,600 KB
testcase_27 AC 90 ms
9,484 KB
testcase_28 AC 95 ms
9,520 KB
testcase_29 AC 81 ms
8,192 KB
testcase_30 AC 87 ms
8,576 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>

#define REP(i,n) for(int i=0;i<(int)(n);i++)
#define ALL(x) (x).begin(),(x).end()

using namespace std;

typedef long long ll;
typedef long double ld;

const ld eps = 1e-9, pi = acos(-1.0);

int main() {
  int N;
  cin >> N;
  vector<ld> T(N), D(N);
  REP(i,N) cin >> T[i];
  REP(i,N) cin >> D[i];
  vector<pair<ld,int>> vec(N);
  REP(i,N) vec[i] = make_pair(D[i] / T[i], i+1);
  sort(ALL(vec));
  REP(i,N) {
    if (i > 0) cout << " ";
    cout << vec[i].second;
  }
  cout << endl;
  return 0;
}
0