The 5th Zhejiang Provincial Collegiate Programming Contest---ProblemE:Easy Task
http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=2969
全场第一水题。我不知道怎么解释,看代码就好了。。。
#include<bits/stdc++.h>
using namespace std;
int main() {
int t,n,a[];
cin>>t;
while(t--) {
cin>>n;
if(n==) {
cin>>a[];
cout<<n<<endl;
} else {
for(int i=n; i>=; i--) {
cin>>a[i];
a[i]*=i;
}
cout<<a[n];
for(int i=n-; i>; i--)
printf(" %d",a[i]);
cout<<endl;
}
}
return ;
}
The 5th Zhejiang Provincial Collegiate Programming Contest---ProblemE:Easy Task的更多相关文章
- nenu contest3 The 5th Zhejiang Provincial Collegiate Programming Contest
ZOJ Problem Set - 2965 Accurately Say "CocaCola"! http://acm.zju.edu.cn/onlinejudge/showP ...
- zoj The 12th Zhejiang Provincial Collegiate Programming Contest May Day Holiday
http://acm.zju.edu.cn/onlinejudge/showContestProblem.do?problemId=5500 The 12th Zhejiang Provincial ...
- 140 - The 12th Zhejiang Provincial Collegiate Programming Contest(第二部分)
Floor Function Time Limit: 10 Seconds Memory Limit: 65536 KB a, b, c and d are all positive int ...
- zoj The 12th Zhejiang Provincial Collegiate Programming Contest Capture the Flag
http://acm.zju.edu.cn/onlinejudge/showContestProblem.do?problemId=5503 The 12th Zhejiang Provincial ...
- zoj The 12th Zhejiang Provincial Collegiate Programming Contest Team Formation
http://acm.zju.edu.cn/onlinejudge/showContestProblem.do?problemId=5494 The 12th Zhejiang Provincial ...
- zoj The 12th Zhejiang Provincial Collegiate Programming Contest Beauty of Array
http://acm.zju.edu.cn/onlinejudge/showContestProblem.do?problemId=5496 The 12th Zhejiang Provincial ...
- zoj The 12th Zhejiang Provincial Collegiate Programming Contest Lunch Time
http://acm.zju.edu.cn/onlinejudge/showContestProblem.do?problemId=5499 The 12th Zhejiang Provincial ...
- zoj The 12th Zhejiang Provincial Collegiate Programming Contest Convert QWERTY to Dvorak
http://acm.zju.edu.cn/onlinejudge/showContestProblem.do?problemId=5502 The 12th Zhejiang Provincial ...
- zoj The 12th Zhejiang Provincial Collegiate Programming Contest Demacia of the Ancients
http://acm.zju.edu.cn/onlinejudge/showContestProblem.do?problemId=5504 The 12th Zhejiang Provincial ...
- zjuoj The 12th Zhejiang Provincial Collegiate Programming Contest Ace of Aces
http://acm.zju.edu.cn/onlinejudge/showContestProblem.do?problemId=5493 The 12th Zhejiang Provincial ...
随机推荐
- 使用spring+mybatis+atomikos+tomcat构建分布式事务
本文通过一个demo,介绍如何使用spring+mybatis+atomikos+tomcat构建在一个事务中涉及两个数据源的web应用. demo功能:实现一个能成功提交和回滚的涉及两个数据库数据源 ...
- Android 全屏相关操作
1.隐藏标题栏(titlebar) (1)在代码中隐藏标题栏 requestWindowFeature(Window.FEATURE_NO_TITLE); (2)在Manifest中Applicati ...
- javascript笔记——date以及datetime的比较
<script src="$!webPath/resources/js/laydate/laydate.js"></script> <script s ...
- item44:将与参数无关的代码抽离template
编写non-template代码中,重复十分明显:可以很直观的看到代码的重复,然后将它们写成一个新的class或者函数,然后供调用. 编写template代码中,重复是隐晦的:只存在一份templat ...
- 2013山东省“浪潮杯”省赛 A.Rescue The Princess
A.Rescue The PrincessDescription Several days ago, a beast caught a beautiful princess and the princ ...
- linux之cat命令
1. cat 接普通文件名,会把文件内容打印到屏幕:2. cat > file,这个可以向文件“file”写入内容,最后按 Ctrl + D 结束输入,会将你输入的数据保存到文件. cat主要有 ...
- 医学影像工作站程序ProDicom的说明
转载 http://blog.csdn.net/prodicom/article/details/4015064 注意:以下内容为转载,但保留了第一人称,请注意,以免造成不必要的麻烦. 医网联影像工作 ...
- 实例讲解如何在Delphi中动态创建dxBarManager内容
一.dxBarManager中一些非常重要的概念: TCategorys:为了方便对dxBarManager中的项目进行归类而设计的一个属性,当然,只使用默认的名字为Default的Category也 ...
- 【转】perl中尖括号运算符(<>)使用说明
perl中尖括号运算符的用途分享,这里简单介绍下,方便需要的朋友 perl中<>运算符可以有如下的用途: 1)如果尖括号中间是文件句柄,尖括号运算符允许你读取文件句柄,比如<STDI ...
- Nginx upstream的5种权重分配方式
.轮询(默认) 每个请求按时间顺序逐一分配到不同的后端服务器,后端服务器down掉,能自动剔除 .weight 指定轮询几率,weight和访问比率成正比,用于后端服务器性能不均的情况. upstre ...