結果

問題 No.568 じゃんじゃん 落とす 委員会
ユーザー WA_TLEWA_TLE
提出日時 2017-08-17 18:27:55
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 1,483 bytes
コンパイル時間 1,382 ms
コンパイル使用メモリ 125,928 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-04-22 15:41:20
合計ジャッジ時間 2,984 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 AC 58 ms
5,376 KB
testcase_03 AC 53 ms
5,376 KB
testcase_04 AC 58 ms
5,376 KB
testcase_05 AC 60 ms
5,376 KB
testcase_06 AC 55 ms
5,376 KB
testcase_07 AC 54 ms
5,376 KB
testcase_08 AC 53 ms
5,376 KB
testcase_09 AC 54 ms
5,376 KB
testcase_10 AC 54 ms
5,376 KB
testcase_11 AC 56 ms
5,376 KB
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 WA -
testcase_23 AC 38 ms
5,376 KB
testcase_24 AC 38 ms
5,376 KB
testcase_25 AC 43 ms
5,376 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<string>
#include<deque>
#include<queue>
#include<vector>
#include<algorithm>
#include<iostream>
#include<set>
#include<cmath>
#include<tuple>
#include<chrono>
#include<functional>
#include<iterator>
#include<random>
#include<unordered_set>
#include<array>
#include<map>
using namespace std;
typedef long long int llint;
#define mp make_pair
#define mt make_tuple
#define pub push_back
#define puf push_front
#define pob pop_back
#define pof pop_front
#define fir first
#define sec second
#define res resize
#define ins insert
#define era erase
const int mod=1000000007;
const int big=1e9+10;
const long double pai=3.141592653589793238462643383279502884197;
const long double eps=1e-9;
template <class T,class U>bool mineq(T& a,U b){if(a>b){a=b;return true;}return false;}
template <class T,class U>bool maxeq(T& a,U b){if(a<b){a=b;return true;}return false;}
llint gcd(llint a,llint b){if(a%b==0){return b;}else return gcd(b,a%b);}
llint lcm(llint a,llint b){return a/gcd(a,b)*b;}
/*

*/
const int maxsei=100001;
int main(void){
	int i,n,m,A,B,ans=big;cin>>n>>m;
	//想定解確認用の愚直
	if(n>1000){return 0;}
	vector<int>x(n);
	vector<int>a(n);
	vector<int>b(n);
	for(i=0;i<n;i++){cin>>x[i]>>a[i]>>b[i];}
	for(A=0;A<=100;A++){
		for(B=0;B<=100;B++){
			int ni=0,san=0;
			for(i=0;i<n;i++){
				int X=x[i];
				if(a[i]>=A){X++;}
				if(b[i]>=B){X++;}
				if(X>=2){ni++;}
				if(X>=3){san++;}
			}
			if(m<=ni&&ans>san){ans=san;}
		}
	}
	cout<<ans<<endl;
	return 0;
}
0