查询各科成绩前三名的记录
分析如下:
1 select s.* from (select distinct Student.*,a.c_id, a.s_score, count( distinct b.s_score)+1 as rank
2 from Score a
3 left join Score b on a.c_id=b.c_id and a....
标准的差分应用题,不要想的太复杂,写成了线段树。
1 #include<bits/stdc++.h>
2 using namespace std;
3 const int N=5e6+10;
4 int d[N],a[N];//d是差分数组
5 int n,p,x,y,z,ans=1e9;
6 int main...
x = int(input("x="))
if x<0 or x > 100:#如果不在0--100区间内输出error
print("error")
elif 100 > x >= 90:#如果在100---90之间输出a
print("a")
elif 90> x >= 80:#如果在90----...