結果
問題 |
No.571 3人兄弟(その2)
|
ユーザー |
![]() |
提出日時 | 2017-10-08 21:31:49 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 7 ms / 2,000 ms |
コード長 | 781 bytes |
コンパイル時間 | 2,585 ms |
コンパイル使用メモリ | 206,836 KB |
最終ジャッジ日時 | 2025-01-05 03:11:19 |
ジャッジサーバーID (参考情報) |
judge5 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 12 |
ソースコード
#include <bits/stdc++.h> using namespace std; #define REP(i,n) for(int i=0; i<(n); i++) #define REP2(i,x,n) for(int i=x; i<(n); i++) #define ALL(n) begin(n),end(n) struct cww{cww(){ios::sync_with_stdio(false);cin.tie(0);}}star; vector<vector<int>> memo( 100 + 1, vector<int>( 10000 + 1, -1 ) ); int main() { vector<tuple<int, int, int>> vc; REP( i, 3 ) { int h, w; cin >> h >> w; vc.emplace_back( make_tuple( h, w, i ) ); } sort( ALL( vc ), []( const auto &x, const auto &y ) { return get<0>( x ) == get<0>( y ) ? get<1>( x ) < get<1>( y ) : get<0>( x ) > get<0>( y ); }); for( auto x : vc ) { cout << ( get<2>( x ) == 0 ? "A" : get<2>( x ) == 1 ? "B" : "C" ) << endl; } return 0; }