十年网站开发经验 + 多家企业客户 + 靠谱的建站团队
量身定制 + 运营维护+专业推广+无忧售后,网站问题一站解决
#include stdio.h
网站设计、成都网站制作介绍好的网站是理念、设计和技术的结合。创新互联拥有的网站设计理念、多方位的设计风格、经验丰富的设计团队。提供PC端+手机端网站建设,用营销思维进行网站设计、采用先进技术开源代码、注重用户体验与SEO基础,将技术与创意整合到网站之中,以契合客户的方式做到创意性的视觉化效果。
int main()
{ float x,y;
scanf("%f"尺饥,x);
if(x陵做返=-1)y=2.5*x;
else if(x=1)y=x;
else y=3*x;
printf("%f\n"胡纳,y);
return 0;
}
int Fun1(int num)
{
if(num 0)
{
return num;
}
else if(num 10)
{
return num - 10;
}
else
{
return num + 10;
}
}
int Fun2(int num)
{
if(num 10)
{
if(num 0)
{
return num;
}
else
{
return num -10;
}
}
else
{
return num +10;
}
}
int Fun3(int num)
{
switch(num0)
{
case 0:
{
switch(num10)
{
case 0:
return num +10;
case 1:
return num - 10;
}
}
case 1:
return num;
}
}
#includestdio.h
#includemath.h
int main()
{double x,y;
scanf("%lf",x);
乱凳if(x=-2x!=5)y=x*x+1/(x+5);
else if(x-2x=0)y=sqrt(x+2)+x*x*x;
else if(x0x=10)y=log(x+5)/log(10)+exp(x-1);
哗绝旅 else y=fabs(x-20);
printf("%lf\n",y);
return 宏扰0;
}
1. 代码如下,3)需要实际运行时输入测试
int main(void)
{
double x, y, f;
printf("Please input 2 double number in the form of x y:\n");
scanf("%lf%lf", x, y);
if(x=0 y0)
f = 2*x*x + 3*x +1/(x+y);
else if(x=0 y=0)
f = 2*x*x + 3*x +1/(1+y*y);
else
f = 3*sin(x+y)/(2*x*x) + 3*x + 1;
printf("x=%lf, y=%lf, f(x, y)=%lf\n", x, y, f);
return 0;
}
2.代码如下
#include stdio.h
#include樱键math.h
int main(void)
{
double x, y, f;
printf("Please input 2 double number in the form of x y:\n");
scanf("%lf%lf", x, y);
if(x=0)
{
if(y0)
f = 2*x*x + 3*x +1/(x+y);
else
f = 2*x*x + 3*x +1/(1+y*y);
}
else
f = 3*sin(x+y)/(2*x*x) + 3*x + 1;
printf("x=%lf, y=%lf, f(x, y)=%lf\n", x, y, f);
return 0;
}
3.代脊答巧码如下
#include stdio.h
int main(void)
{
int score = 0;
printf("Please input a score between 0-100:\n");
scanf("%d", score);
if(score举败0 || score100)
printf("Wrong input of score!\n");
else if(score=90 score=100)
printf("A\n");
else if(score=80 score=89)
printf("B\n");
else if(score=70 score=79)
printf("C\n");
else if(score=60 score=69)
printf("D\n");
else
printf("E\n");
return 0;
}