Catherine_zhilin

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理
上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 33 下一页

2019年7月4日

摘要: 交换两个数的基本逻辑 1 #include <stdio.h> 2 3 int main(){ 4 int a[10]={3,1,4,5,2}; 5 int i,j,k; 6 for(i=1;i<=4;i++) {//进行n-1次比较 7 //从i趟时从a[0]到a[n-i-1]都与他们下一个数比较 阅读全文
posted @ 2019-07-04 15:16 kkkshiki 阅读(355) 评论(0) 推荐(0)

摘要: 数组 1 #include <stdio.h> 2 3 int main(){ 4 int a[10]={5,3,2,6,8,4}; 5 int i; 6 for(i=0;i<10;i++){ 7 printf("a[%d]=%d\n",i,a[i]); 8 9 } 10 return 0; 11 阅读全文
posted @ 2019-07-04 14:59 kkkshiki 阅读(142) 评论(0) 推荐(0)

摘要: 常用math函数 1 #include <stdio.h> 2 #include <math.h> 3 4 /*绝对值*/ 5 int main(){ 6 double db=-12.56; 7 printf("%.2f\n",fabs(db)); 8 return 0; 9 } 1 #includ 阅读全文
posted @ 2019-07-04 11:35 kkkshiki 阅读(168) 评论(0) 推荐(0)

摘要: 1 #include <stdio.h> 2 3 4 /* run this program using the console pauser or add your own getch, system("pause") or input loop */ 5 /*输出数据1 换行2 输出数据2 ;计 阅读全文
posted @ 2019-07-04 11:03 kkkshiki 阅读(209) 评论(0) 推荐(0)

摘要: C C++比较: 1. Scanf printf 函数 Cin cout可不指定输入输出格式,消耗时间多 2. Stdio :standard input output .h——head Stdio.h ——include sth about input and output (cstdio) #i 阅读全文
posted @ 2019-07-04 08:41 kkkshiki 阅读(91) 评论(0) 推荐(0)

2019年3月22日

摘要: 第一步 建立工程 netbeans-->java web -->web application 第二步 创建Java类 在Java类中写入变量元素并且构建封装字段 1 /* 2 * To change this license header, choose License Headers in Pr 阅读全文
posted @ 2019-03-22 17:41 kkkshiki 阅读(218) 评论(0) 推荐(0)

2019年3月2日

摘要: 1002 A+B for Polynomials This time, you are supposed to find A+B are two polynomials. Input Specification: Each input file contains one test case.Each 阅读全文
posted @ 2019-03-02 10:45 kkkshiki 阅读(210) 评论(0) 推荐(0)

摘要: 阅读全文
posted @ 2019-03-02 09:10 kkkshiki 阅读(159) 评论(0) 推荐(0)

摘要: 字符串转化为整形 Java中有两个可选的方法用来将字符串转成整型。 一个是Integer.parseInt(),另外一个是Ingeger.valueOf()。 这两个方法都是java.lang.Integer类中的静态方法。 当输入的字符串不是有效的整数,这两个方法都会抛出NumberFormatE 阅读全文
posted @ 2019-03-02 08:45 kkkshiki 阅读(2617) 评论(0) 推荐(0)

摘要: 1001 A+BFromat Calculate a+b and output the sum in standard format -- that is,the diits must be seperated into groups of three commas (unless there ar 阅读全文
posted @ 2019-03-02 08:40 kkkshiki 阅读(319) 评论(0) 推荐(0)

上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 33 下一页