Compare commits

..

No commits in common. "cad8519840de517d546b985160421e96cd395cfb" and "94327119bbeb25888d09fe25ff34895ab8ae3bd2" have entirely different histories.

8 changed files with 0 additions and 75 deletions

View file

@ -1,68 +0,0 @@
#include <bits/stdc++.h>
#include <iostream>
using namespace std;
struct tanulok {
int ev;
int ho;
int nap;
int kezdes;
int vegzes;
};
int main() {
int n;
cin >> n;
vector<tanulok> tan(n);
for (int i = 0; i < n; i++) {
cin >> tan[i].ev >> tan[i].ho >> tan[i].nap >> tan[i].kezdes >> tan[i].vegzes;
}
int max = 0;
int maxI;
bool tovabb = false;
vector<int> a;
for (int i = 0; i < n; i++) {
if (max < tan[i].ev) {
max = tan[i].ev;
maxI = i;
}
}
for (int i = 0; i < n; i++) {
if (max == tan[i].ev) {
a.push_back(i);
}
}
max = 0;
// for (int i = 0; i < a.size(); i++) {
// cout<<a[i]<<' ';
// }
//cout<<endl;
vector<int> b;
for (int i = 0; i < a.size(); i++) {
if (max < tan[a[i]].ho) {
max = tan[a[i]].ho;
maxI = a[i];
//cout<<"if fired "<< i<<' '<< a[i] <<' '<<tan[a[i]].ho<<endl;
}
}
for (int i = 0; i < n; i++) {
if (max == tan[i].ho) {
b.push_back(i);
}
}
max =0;
for (int i = 0; i < b.size(); i++) {
if (max < tan[b[i]].nap) {
max = tan[b[i]].nap;
maxI = b[i];
//cout<<"if fired "<< i<<' '<< a[i] <<' '<<tan[a[i]].ho<<endl;
}
}
cout << tan[maxI].ev << ' '<<tan[maxI].ho<<' '<<tan[maxI].nap;
}

View file

@ -1,7 +0,0 @@
#include <bits/stdc++.h>
#include <iostream>
using namespace std;
int main() {
}

BIN
hf2/hf4/3 Executable file

Binary file not shown.