Run ID:131051
提交时间:2025-09-20 17:21:38
#include<bits/stdc++.h> using namespace std; struct book{ int c; string b; int s; int z,d; void input(){ cin>>c>>b>>s>>z; d=z/s; } void output(){ cout<<c<<" "<<b<<" "<<s<<" "<<z<<" "<<d<<endl; } }a[101]; int main() { int n; cin>>n; book maxn={0," ",0,0,0}; for(int i=0;i<n;i++){ a[i].input(); if(a[i].d>maxn.d){ maxn=a[i]; } } maxn.output(); return 0; }