#import<Foundation/Foundation.h>
intmain(intargc,constchar*argv[])
{
@autoreleasepool{
NSString*tempStr;
//将要分割的字符串
NSMutableString*mutableString=[[NSMutableStringalloc]initWithString:@"hello,world!nihao"];
//分割字符串的字符集
NSCharacterSe..
分类:
编程语言 时间:
2014-09-21 21:26:32
阅读次数:
250
二、通常的函数调用一个通常的函数调用的例子:/* 自行包含头文件 */void MyFun(int x); /* 此处的声明也可写成:void MyFun(int) */int main(int argc, char* argv[]){ MyFun(10); /* 这里是调用MyFun(10) 函数...
分类:
其他好文 时间:
2014-09-21 14:59:30
阅读次数:
250
如不做特殊说明,本博客所使用的 nginx 源码版本是 1.0.14我们先贴出 main 函数的部分代码: 205 int ngx_cdecl 206 main(int argc, char *const *argv) 207 { 208 ngx_int_t i; 209...
分类:
其他好文 时间:
2014-09-20 15:41:29
阅读次数:
391
from sys import argvinput(argv)#python自带的IDLE直接执行不能提供命令行参数script,first,second,third=argvprint("The script is called:",script)print("Your first variabl...
分类:
其他好文 时间:
2014-09-20 14:40:48
阅读次数:
522
获取web页面#!/usr/bin/envpython
importsys,urllib2
req=urllib2.Request(sys.argv[1])
fd=urllib2.urlopen(req)
whileTrue:
data=fd.read(1024)
ifnotlen(data):
break
sys.stdout.write(data)首先建立了一个urllib2.Request对象,该对象用URL做参数。然后调用urlopen得到..
分类:
Web程序 时间:
2014-09-20 02:22:57
阅读次数:
332
main 入口参数:argc 和 argv#include void main (int argc, char **argv){ int i; printf("argc:%d\n",argc); for (i=0; i<argc; i++) printf("argv[...
分类:
其他好文 时间:
2014-09-20 01:02:26
阅读次数:
161
int main(int argc, const char * argv[]) { f(1,1,1000); return 0;}void f(int a,int b,int n){ if (a<n) { printf("%d\n",a); a=a+b; f(b,a,n);...
分类:
其他好文 时间:
2014-09-19 21:07:06
阅读次数:
168
上传文件:http://zengrong.net/post/2088.htm#include #include #include int main(int argc, char *argv[]){ CURL *curl; CURLcode res; struct curl_httppos...
分类:
其他好文 时间:
2014-09-19 19:18:05
阅读次数:
168
#include int main(int argc, const char * argv[]) { char cost,top; cost=getchar(); if (cost>='a'&&cost='A'&&costj ; k--) { printf(" "); } ...
分类:
编程语言 时间:
2014-09-18 21:52:24
阅读次数:
588
#include
#include
#include
#include
int main( int argc, char** argv )
{
//声明IplImage指针
IplImage* pFrame = NULL;
IplImage* pFrImg = NULL;
IplImage* pBkImg = NULL;
CvMat* pFrameMat =...
分类:
其他好文 时间:
2014-09-18 19:02:17
阅读次数:
256