Run ID:84446

提交时间:2024-07-16 09:24:04

#include<bits/stdc++.h> using namespace std; int main() { int n; cin>>n; int p1,p2,p3; int t[n]={0}; for(int i=0;i<n;i++){ cin>>p1>>p2>>p3; t[p1]++; t[p2]++; t[p3]++; } int bz=0; for(int j=0;j<n;j++){ if(t[j]>t[bz]){ bz=j; } } cout<<bz; return 0; }