摘要:
Problem DescriptionGiven a sequence 1,2,3,......N, your job is to calculate all the possible sub-sequences that the sum of the sub-sequence is M.Input... 阅读全文
posted @ 2014-12-02 18:23
fish7
阅读(169)
评论(0)
推荐(0)
摘要:
有如下方程:Ai= (Ai-1+ Ai+1)/2 - Ci(i = 1, 2, 3, .... n).若给出A0, An+1, 和 C1, C2, .....Cn.请编程计算A1= ?Input输入包括多个测试实例。 对于每个实例,首先是一个正整数n,(n >n){ cin>>ax>>... 阅读全文
posted @ 2014-12-02 17:56
fish7
阅读(193)
评论(0)
推荐(0)
摘要:
/** * static关键字:修饰属性(实质就是全局变量)、方法(无需本类的对象即可调用此方法)、类。 * 1.static方法只能调用static方法 * 2.static方法只能访问static数据 * 3.static方法不能以任何方式引用this或super */public class ... 阅读全文
posted @ 2014-12-02 16:45
fish7
阅读(313)
评论(0)
推荐(0)
摘要:
import java.lang.String;import java.util.Scanner;public class Main { public static void main(String[] args) { //方式一:会创建两个字符串对象(会在字符串常量池中也存一份... 阅读全文
posted @ 2014-12-02 15:25
fish7
阅读(274)
评论(0)
推荐(0)
浙公网安备 33010602011771号