結果

問題 No.1475 時計の歯車Easy
ユーザー 👑 CleyL
提出日時 2021-08-08 15:52:00
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 446 bytes
コンパイル時間 715 ms
コンパイル使用メモリ 74,624 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-09-19 12:12:08
合計ジャッジ時間 1,689 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 42
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int main(){
    int n;cin>>n;
    for(int i = 0; n > i; i++){
        int m;cin>>m;
        vector<int> A(m);
        for(int j = 0; m > j; j++){
            cin>>A[j];
        }
        sort(A.begin(),A.end(),greater<int>());
        for(int j = 0; m > j; j++){
            cout << A[j];
            if(j+1 != m) cout << " ";
        }
        cout << endl;
    }
}
0