結果

問題 No.1121 Social Distancing in Cinema
ユーザー okok
提出日時 2020-07-23 21:45:48
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 1,031 bytes
コンパイル時間 795 ms
コンパイル使用メモリ 87,620 KB
実行使用メモリ 4,384 KB
最終ジャッジ日時 2023-09-06 01:17:11
合計ジャッジ時間 14,671 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1 ms
4,376 KB
testcase_01 AC 1 ms
4,376 KB
testcase_02 AC 1 ms
4,380 KB
testcase_03 AC 1 ms
4,376 KB
testcase_04 AC 1 ms
4,376 KB
testcase_05 AC 2 ms
4,380 KB
testcase_06 AC 2 ms
4,380 KB
testcase_07 AC 2 ms
4,376 KB
testcase_08 AC 2 ms
4,380 KB
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 RE -
testcase_14 RE -
testcase_15 RE -
testcase_16 RE -
testcase_17 RE -
testcase_18 RE -
testcase_19 RE -
testcase_20 RE -
testcase_21 RE -
testcase_22 RE -
testcase_23 RE -
testcase_24 RE -
testcase_25 RE -
testcase_26 RE -
testcase_27 RE -
testcase_28 RE -
testcase_29 RE -
testcase_30 RE -
testcase_31 RE -
testcase_32 RE -
testcase_33 RE -
testcase_34 RE -
testcase_35 RE -
testcase_36 RE -
testcase_37 RE -
testcase_38 RE -
testcase_39 RE -
testcase_40 RE -
testcase_41 RE -
testcase_42 RE -
testcase_43 RE -
testcase_44 RE -
testcase_45 RE -
testcase_46 RE -
testcase_47 WA -
testcase_48 AC 2 ms
4,380 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<iostream>
#include<string>
#include<iomanip>
#include<cmath>
#include<vector>
#include<algorithm>
#include<utility>

using namespace std;

#define int long long
#define endl "\n"

constexpr long long INF = (long long)1e18;
constexpr long long MOD = 1'000'000'007; 

struct fast_io {
	fast_io(){
		std::cin.tie(nullptr);
		std::ios::sync_with_stdio(false);
	};
} fio;

signed main(){
	cout<<fixed<<setprecision(10);
	
	int N;
	vector<vector<vector<pair<int,int>>>> c(9, vector<vector<pair<int,int>>>(10));
	
	cin>>N;
	
	for(int i = 0; i < N; i++){
		int x, y;
		
		cin>>x>>y;
		
		if(x%18 < 9) {
			c[x%18][y%10].emplace_back(x,y);
			
		} else {
			c[x-9][(y+5)%10].emplace_back(x,y);
		}
	}
	
	for(int i = 0; i< c.size(); i++){
		for(int j = 0; j < c[i].size(); j++){
			if(c[i][j].size() * 90 >= N) {
				cout<<c[i][j].size()<<endl;
				
				for(int k = 0; k < c[i][j].size(); k++){
					if(k) cout<<" ";
					cout<<c[i][j][k].first<<" "<<c[i][j][k].second;
				}
				cout<<endl;
				return 0;
			}
		}
	}
	
	return 0;
}
0