1 // typesize.c -- 输出类型的大小 2 #include 3 int main(void) 4 { 5 //C99为类型大小提供一个%zd说明符 6 7 printf("Type int has a size of %u bytes. \n", sizeof(...
分类:
其他好文 时间:
2014-06-28 23:13:47
阅读次数:
245
1显示程序执行的窗口一闪即逝。可以添加如下语句:getchar()作用是获取键盘输入。2 inf 和 nanfloat toobig = 3.4e38 * 100.0f; float not_a_number = asin(1.2);//math.h printf("%e \t %e\n",...
分类:
其他好文 时间:
2014-06-28 21:57:22
阅读次数:
305
sprintf(vFilter->szOverLay,"movie=%s[wm];[in][wm]overlay=%d:%d[out]",szOverlay,x,y);当szOverlay = “d:\\xxx\xxx.png”; 时返回-2,貌似ffmpeg处理不了路径中的冒号。。。用当前路径下的...
分类:
其他好文 时间:
2014-06-18 19:04:31
阅读次数:
1066
#includevoid equal(int a[],int N){ int i; for(i=0;i<N;i++) { if(i<a[i]) { printf("no exist\n"); printf("%...
分类:
其他好文 时间:
2014-06-18 17:49:42
阅读次数:
191
广播模型broadcast.c 1 #include 2 3 #define PORT 8088 4 5 int main(int argc,char **argv) 6 { 7 if(argc!=2) 8 { 9 printf("%s \n",argv[0])...
分类:
其他好文 时间:
2014-06-18 15:55:32
阅读次数:
189
#include"stdio.h"int main(){int a;int n=0;scanf("%d",&a);n++;a=a/10;while(a>0){n++;a=a/10;}printf("%d",n);return 0;}
分类:
其他好文 时间:
2014-06-18 13:43:35
阅读次数:
201
1. sizeof(literal-string) is number of bytes plus 1 (NULL is included), while strlen(literal-string) is number of bytes.2. Printf and scanf formatBefo...
分类:
其他好文 时间:
2014-06-18 10:14:22
阅读次数:
226
#import
//交换函数
void swap(int x, int y)
{
printf("x=%d,y=%d",x,y);
int temp = 0;
temp = x;
x = y;
y = temp;
printf("x=%d,y=%d",x,y);
}
//
void swap2(int *x , int *y)...
分类:
编程语言 时间:
2014-06-18 07:10:13
阅读次数:
302
把 c 编译成 arm 指令的可执行文件
/usr/bin/arm-linux-gnueabi-g++ hello.cpp
cat hello.cpp
#include
void crash(){
char *a=0;
*a=0;
}
int main()
{
printf("hello world\n");
crash();...
分类:
数据库 时间:
2014-06-18 06:50:45
阅读次数:
424
本文是笔者对printf的一种全新的尝试,自己发现了一些printf与众不同的功能...
分类:
其他好文 时间:
2014-06-18 00:59:35
阅读次数:
195