博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
1025. PAT Ranking (25)
阅读量:4071 次
发布时间:2019-05-25

本文共 811 字,大约阅读时间需要 2 分钟。

传送门://

AC代码

#include 
#include
#include
#include
#include
#include
#include
using namespace std;struct student{ char id[14]; int score,localTest,localRank,totalRank; bool operator>(const student &target){ if(score!=target.score) return score>target.score; else return strcmp(id, target.id)<0; }};int main(){ int n,m; scanf("%d",&n); vector
allStudents; vector
>LocalsocreCount(n,vector
(101,0)); vector
AllsocreCount(101,0); int start = 0,end=0; for (int i=0; i
=0; j--) LocalsocreCount[i][j]+= LocalsocreCount[i][j+1]; end = end +m; for (int j = start; j
=0; i--) { AllsocreCount[i]+= AllsocreCount[i+1]; } sort(allStudents.begin(), allStudents.end(), [](student a,student b){ return a>b; }); printf("%d\n",(int)allStudents.size()); for (int i=0; i

转载地址:http://oqhji.baihongyu.com/

你可能感兴趣的文章
OS + Unix Aix telnet
查看>>
IBM Lotus
查看>>
Linux +Win LAMPP Tools XAMPP 1.7.3 / 5.6.3
查看>>
my read_university
查看>>
network manager
查看>>
OS + Linux Disk disk lvm / disk partition / disk mount / disk io
查看>>
RedHat + OS CPU、MEM、DISK
查看>>
net TCP/IP / TIME_WAIT / tcpip / iperf / cain
查看>>
webServer kzserver/1.0.0
查看>>
hd printer lexmark / dazifuyin / dayin / fuyin
查看>>
OS + Unix IBM Aix basic / topas / nmon / filemon / vmstat / iostat / sysstat/sar
查看>>
my ReadMap subway / metro / map / ditie / gaotie / traffic / jiaotong
查看>>
OS + Linux DNS Server Bind
查看>>
linux内核模块中 软中断的 例子
查看>>
grails中主键的uuid生成方式
查看>>
grails下acegi的访问规则的配置
查看>>
纯c封装的一个队列
查看>>
linux中时间精度的获取问题
查看>>
cancel_rearming_delayed_workqueue 函数使用的一个小备注
查看>>
使用LOGFONT修改windows sdk下字体为系统字体
查看>>