A. GukiZ and Contest-Codeforces Round #307 (Div. 2)-简单水题
2015-08-07 19:27
363 查看
#include <cstring> #include <string> #include <algorithm> #include <iostream> #include <queue> #include <map> #include <set> #include <vector> using namespace std; int a[2000+5]; int vis[2000+5]; int main() { int i,j,n; scanf("%d",&n); for (i=1;i<=n;i++) { scanf("%d",&a[i]); vis[a[i]]++; } for (i=1;i<=n;i++) { int cun=0; for (j=2000;j>a[i];j--) { if (vis[j]) cun+=vis[j]; } if (i!=1) printf(" "); printf("%d",1+cun); } cout<<endl; return 0; }
相关文章推荐
- POJ-2242 The Circumference of the Circle-已知三点共圆求周长
- 门面模式(Facade)解析
- 门面模式(Facade)解析
- POJ-2752-Seek the Name, Seek the Fame
- android 设置全屏,窗口透明度,待机设置,主题设置总结
- Objective-C文章中的生词
- hdu 5340 Three Palindromes
- C++(13)STL实践与分析之再谈String类型
- 简单工程模式--计算机
- 【CF245H】【Queries for Number of Palindromes】
- POJ-2196 Specialized Four-Digit Numbers-10,12,16进制的各个位数相加彼此相等的数
- JavaScript——实现时间的动态显示
- B. ZgukistringZ-简单字符串处理-Codeforces Round #307 (Div. 2)
- MySQL使用说明
- 在Linux中创建静态库.a和动态库.so
- 熟人Dubbo 系列1-Dubbo什么
- 在windows 、linux下读取目录下所有文件名
- hdu 5363 Key Set(水)
- javascriptcore.framework学习.
- hdu 5361 In Touch(最短路+并查集)