Submission #64038144


Source Code Expand

Copy
#include<bits/stdc++.h>
using namespace std;
#define int long long
#define debug() cout<<"come on"<<'\n'
#define mkp make_pair
#define pb push_back
#define ft first
#define sd second
typedef pair<int,int> pii;
typedef pair<int,pii> piii;
map<int,int> mp;
int cnt[114514],c1,c2;
signed main(){
cnt[0]=114514;
for(int i=1,x;i<=7;i++){
cin>>x;
mp[x]++;
cnt[mp[x]-1]--,cnt[mp[x]]++;
}
for(int i=3;i<=7;i++){
c1+=cnt[i];
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
#include<bits/stdc++.h>
using namespace std;
#define int long long
#define debug() cout<<"come on"<<'\n'
#define mkp make_pair
#define pb push_back
#define ft first
#define sd second
typedef pair<int,int> pii;
typedef pair<int,pii> piii;
map<int,int> mp;
int cnt[114514],c1,c2;
signed main(){
	cnt[0]=114514;
	for(int i=1,x;i<=7;i++){
		cin>>x;
		mp[x]++;
		cnt[mp[x]-1]--,cnt[mp[x]]++;
	}
	for(int i=3;i<=7;i++){
		c1+=cnt[i];
	}
	if(c1>=2)cout<<"Yes";
	else if(cnt[2]>=1&&c1==1)cout<<"Yes";
	else cout<<"No";
	return 0;
}

Submission Info

Submission Time
Task B - Full House 3
User dulf2024
Language C++ 20 (gcc 12.2)
Score 250
Code Size 551 Byte
Status AC
Exec Time 1 ms
Memory 3684 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 250 / 250
Status
AC × 4
AC × 34
Set Name Test Cases
Sample sample_01.txt, sample_02.txt, sample_03.txt, sample_04.txt
All hand_01.txt, hand_02.txt, hand_03.txt, hand_04.txt, sample_01.txt, sample_02.txt, sample_03.txt, sample_04.txt, test_01.txt, test_02.txt, test_03.txt, test_04.txt, test_05.txt, test_06.txt, test_07.txt, test_08.txt, test_09.txt, test_10.txt, test_11.txt, test_12.txt, test_13.txt, test_14.txt, test_15.txt, test_16.txt, test_17.txt, test_18.txt, test_19.txt, test_20.txt, test_21.txt, test_22.txt, test_23.txt, test_24.txt, test_25.txt, test_26.txt
Case Name Status Exec Time Memory
hand_01.txt AC 1 ms 3492 KB
hand_02.txt AC 1 ms 3540 KB
hand_03.txt AC 1 ms 3492 KB
hand_04.txt AC 1 ms 3460 KB
sample_01.txt AC 1 ms 3524 KB
sample_02.txt AC 1 ms 3536 KB
sample_03.txt AC 1 ms 3500 KB
sample_04.txt AC 1 ms 3680 KB
test_01.txt AC 1 ms 3560 KB
test_02.txt AC 1 ms 3496 KB
test_03.txt AC 1 ms 3552 KB
test_04.txt AC 1 ms 3680 KB
test_05.txt AC 1 ms 3528 KB
test_06.txt AC 1 ms 3460 KB
test_07.txt AC 1 ms 3488 KB
test_08.txt AC 1 ms 3496 KB
test_09.txt AC 1 ms 3544 KB
test_10.txt AC 1 ms 3684 KB
test_11.txt AC 1 ms 3556 KB
test_12.txt AC 1 ms 3684 KB
test_13.txt AC 1 ms 3660 KB
test_14.txt AC 1 ms 3480 KB
test_15.txt AC 1 ms 3680 KB
test_16.txt AC 1 ms 3560 KB
test_17.txt AC 1 ms 3480 KB
test_18.txt AC 1 ms 3620 KB
test_19.txt AC 1 ms 3456 KB
test_20.txt AC 1 ms 3524 KB
test_21.txt AC 1 ms 3496 KB
test_22.txt AC 1 ms 3500 KB
test_23.txt AC 1 ms 3480 KB
test_24.txt AC 1 ms 3488 KB
test_25.txt AC 1 ms 3544 KB
test_26.txt AC 1 ms 3500 KB


2025-03-30 (Sun)
09:44:15 +00:00