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+MN/9UeAgDnYJ/jDckIg9wAAGdon/dFtlHhv3/+EhsA4Pzs8fsbNl/eIDQAwFnyfZEAQJTcAABEyQ0AQJTcAABEyQ0AQJTcAABEyQ0AQJTcAABEyQ0AQJTcAABEyQ0AQFQ0NwAA/BvJDQAAA+QGACBKbgAAouQGACBKbgAAouQGACBKbgAAouQGACBKbgAAov4/Ftde9SFN6PcAAAAASUVORK5CYII=" alt="" />
--------------------------------------
需要注意的地方就是n的绝对值不大于10000,表示n有可能是负数。
AC代码:
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws NumberFormatException, IOException { BufferedReader reader=new BufferedReader(new InputStreamReader(System.in)); boolean first=true;
while(first || reader.ready()){
first=false; int n=Integer.parseInt(reader.readLine());
long ans=n;
if(n>0){
while(--n>=1) ans+=n;
}else{
while(++n<=1) ans+=n;
}
System.out.println(ans);
} } }
题目来源: http://acm.nyist.net/JudgeOnline/problem.php?pid=436
NYOJ题目436sum of all integer numbers的更多相关文章
- Integer Numbers
ZOJ Problem Set - 3365 Integer Numbers Time Limit: 1 Second Memory Limit: 32768 KB Special ...
- ZOJ 3365 Integer Numbers
Integer Numbers Time Limit: 1000ms Memory Limit: 32768KB This problem will be judged on ZJU. Origina ...
- NYOJ题目20吝啬的国度
-----------------------------------------n-1条边的无向连通图是一棵树,又因为树上两点之间的路径是唯一的,所以解是唯一的.(注意并不一定是二叉树,所以最好采用 ...
- NYOJ题目168房间安排
aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAssAAAOTCAIAAADGwNmiAAAgAElEQVR4nOy9PY7cyLPufTchXwsZu9
- NYOJ题目125盗梦空间
aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAssAAANLCAIAAAA4rUfgAAAgAElEQVR4nOydq7LdyrKm+yXM/SDG4y
- NYOJ题目111分数加减法
aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAsEAAAKBCAIAAAA5i+FPAAAgAElEQVR4nO3dPXLbugMv7LsJ916Iay ...
- NYOJ题目112指数运算
aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAs0AAAIICAIAAAAaCETRAAAgAElEQVR4nO3drW7jWtwv4PcmwnMhxb ...
- NYOJ题目100 1的个数
aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAsMAAAIqCAIAAABOpdBfAAAgAElEQVR4nO3drXLbzP834P9JhOdAgn ...
- NYOJ题目96 n-1位数
aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAscAAAJgCAIAAADpjVkvAAAgAElEQVR4nO3du04jS/gv7H0T5FwIsa ...
随机推荐
- Java多线程基础知识(三)
一. 管道输入/输出流 它和其它文件输入/输出流或网络输入/输出流的不同之处,它主要是线程之间的数据传输,而传输的媒介是内存. 管道输入/输出流主要包含四中实现: 1. PipedOutputStre ...
- jetbrick,新一代 Java 模板引擎,具有高性能和高扩展性
新一代 Java 模板引擎,具有高性能和高扩展性. <!-- Jetbrick Template Engineer --> <dependency> <groupId&g ...
- [转载]html中DTD使用小结
原文链接:http://www.jb51.net/web/36856.html DTD 是一套关于标记符的语法规则.它是XML1.0版规格得一部分,是html文件的验证机制,属于html文件组成的一部 ...
- 学号160809224姓名黄家帅c语言程序设计实验2 选择结构程序设计
实验2-1 输入3个数,并按由大到小的顺序输出. 实验要求: 编写一个C程序,输入3个数,并按由大到小的顺序输出. 源码: #include <stdio.h>void main(){ i ...
- SQL 多表一起查询的语句总结
sql 同时查询多个表 可以使用连表查询比如使用join sql 同时查询多个表 可以使用连表查询 比如 使用join select s1.*,s2.* from s1 left join s2 on ...
- am等adb命令小总结
本文的am部分参考了:http://www.cnblogs.com/dyllove98/archive/2013/07/08/3178094.html 的博客 今天研究adb的时候发现在pc端也可以启 ...
- Hashtable和HashMap类的区别
Hashtable和HashMap类有三个重要的不同之处.第一个不同主要是历史原因.Hashtable是基于陈旧的Dictionary类的,HashMap是Java 1.2引进的Map接口的一个实现. ...
- Ubuntu14.04安装intel集显驱动
Ubuntu14.04安装intel集显驱动 标签(空格分隔): ubuntu linux 驱动安装 1.查看本机显卡型号 使用lspci命令来获取PCI接口硬件信息 o@o-pc:~$ lspci ...
- AJAX 页面数据传递
$.ajax({ //一个Ajax过程 type: "post", //以post方式与后台沟通 url: "personstockajax.php", //与 ...
- 9.1---上楼梯(CC150)
注意:错误主要在溢出问题上.所以不设置int,而是long. public static int countWays(int n){ if(n == 1) return 1; if(n == 2) r ...