您的位置:首页 > 运维架构 > Apache

Solaris上利用pkgutil工具安装Apache、MySQL和PHP

2010-12-14 11:41 381 查看
#include <stdio.h>
#include <stdbool.h>

int main(void)
{
float input;
bool isTrue = (scanf("%f",&input) == 1);
while(isTrue)
{
printf("it's %.d\n",(int)input);//输入的小于1就不会打印出来
isTrue = (scanf("%f",&input) == 1);
}
}
/*当只需获取一个输入时,可以向下面的这样做*/
#include <stdio.h>
int main(void)
{
char boop;
while(scanf("%c",&boop) == 1)
{
while(getchar() != '\n')
continue;
printf("It's %c",boop);
}
}
//等同于下面的程序

#include <stdio.h>
int main(void)
{
char boop;
while(gets(&boop))
{
printf("It's %c",boop);
}
}

本文出自 “天才的实力” 博客,转载请与作者联系!
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: