输出大V;
#include<stdio.h>
int main()
{
printf("v v\n");
printf(" v v\n");
printf(" v\n");
return 0;
}
输出下列关键字的储存空间
```c
#include<stdio.h>
int main()
{
printf("The size of short is %d bytes.\n", sizeof(short));
printf("The size of int is %d bytes.\n", sizeof(int));
printf("The size of long is %d bytes.\n", sizeof(long));
printf("The size of long long is %d bytes.\n", sizeof(long long));
return 0;
}
打印小飞机
```c
#include<stdio.h>//打印小飞机
int main()
{
printf(" **\n");
printf(" **\n");
printf("************\n");
printf("************\n");
printf(" * * \n");
printf(" * * \n");
return 0;
}
十进制数1234由八进制、十六进制输出。
#include<stdio.h>
int main()
{
int i=1234;
printf("%d\n", i);
printf("%#o\n",1234);
printf("%#x\n",1234);
return 0;
}
输出"Hello world!",输出printf(“Hello world!”)返回值。
#include<stdio.h>
int main()
{
int a = printf("Hello world!");
printf("\n");
printf("%d", a);
return 0;
}