#include <stdio.h>//1172.因子和#include <math.h>int main(){ long n; int i, sum; while(scanf("%d", &n)&&n!=0) { sum = 0; if(n==1){printf("1\n");continue;} ...
分类:
其他好文 时间:
2016-09-30 23:25:02
阅读次数:
218
最近在开发的一个项目,需要涉及到使用Http请求发送比较大的数据,研究了挺长时间,遇到问题,解决问题,在此分享给大家 1.由于数据量较大,所以采用POST方式 传输数据(POST理论上不限制数据大小,但不同服务器都会有相应的默认设置限制数据大小) 2.由于项目需要,使用JSON格式的数据 代码示例: ...
分类:
Web程序 时间:
2016-09-30 18:16:56
阅读次数:
1568
Pexpect是一个用来启动子程序并对其进行自动控制的纯Python模块。Pexpect可以用来和像ssh、ftp、passwd、telnet
等命令行程序进行自动交互。defssh_cmd(ip,user,passwd,cmd):result=‘‘ssh=pexpect.spawn(‘ssh%s@%s"%s"‘%(user,ip,cmd))try:i=ssh.expect([‘password:‘,‘continue..
分类:
编程语言 时间:
2016-09-29 11:29:16
阅读次数:
212
使用codeblocks避免不了快捷键: 在调试程序的时候: 首先在view->toolbar->debugger调出来:快捷方式可以自己看 RUN to Cursor :F4 单步调试(Next line):F7 可以打断点,执行debugger中start/continue F8 //执行到断点 ...
分类:
其他好文 时间:
2016-09-28 12:43:40
阅读次数:
243
循环有三种:while,do...while,for循环; 关键字:continue,break; 循环的三个条件:1、赋初始值2、改变循环变量3、终止循环条件 while的100之内的所有数的和 for循环实现100以内数的和 九九乘法表 ...
分类:
编程语言 时间:
2016-09-27 20:14:39
阅读次数:
161
This is my first blog post in many years, and I want to continue writing things from this blog, which is called Weird Wired Things (Is the name weird? ...
分类:
其他好文 时间:
2016-09-27 13:25:10
阅读次数:
127
消息 描述 100 Continue 服务器仅接收到部分请求,但是一旦服务器并没有拒绝该请求,客户端应该继续发送其余的请求。 101 Switching Protocols 服务器转换协议:服务器将遵从客户的请求转换到另外一种协议。 消息 描述 200 OK 请求成功(其后是对GET和POST请求的 ...
分类:
Web程序 时间:
2016-09-26 20:12:55
阅读次数:
180
2:continue&&outermost 这种情况下会退出内部循环,执行外部循环,也就意味着内部循环少执行了5次 3:switch case语句,假如有多个if else 用switch case可以精准定位到满足条件的语句,性能好 4:通过arguments对象的length属性可以获知有多少个 ...
分类:
其他好文 时间:
2016-09-25 16:03:19
阅读次数:
163
摘要 python实现的几个业务部门常用的周报表,用pyinstaller打包成独立的exe文件,添加到windows任务计划,每周的第一天上班前打印出周报表。 构件图 to be continue... ...
分类:
其他好文 时间:
2016-09-24 23:24:50
阅读次数:
145
一、awk控制语句类型 {statements;…}组合语句 if(condition){statements;…} if(condition){statements;…}else{statements;…} while(conditon){statments;…} do{statements;…}while(condition) for(expr1;expr2;expr3){statements;…} break continue deletearray[index] ..
分类:
其他好文 时间:
2016-09-21 08:01:58
阅读次数:
369