网友您好, 请在下方输入框内输入要搜索的题目:
题目内容
(请给出正确答案)
根据三角形的基本定理完成填空,则表达式应为______。 include include void
根据三角形的基本定理完成填空,则表达式应为______。
include<iostream.h>
include<math.h>
void main( )
{
double a,b,e,s,area;
cout<<"请输入三角形三边a,b,e,"<<endl;
cin>>a>>b>>c;
if(______)
{
s=(a+b+c)/2;
area=sqrt(s*(s-a)*(s-b)*(s-c));
cout<<"三角形的面积为:"<<area;
}
else
cout<<"不能构成三角形!"<<endl;
}
参考答案
更多 “ 根据三角形的基本定理完成填空,则表达式应为______。 include include void 根据三角形的基本定理完成填空,则表达式应为______。include<iostream.h>include<math.h>void main( ){double a,b,e,s,area;cout<<"请输入三角形三边a,b,e,"<<endl;cin>>a>>b>>c;if(______){s=(a+b+c)/2;area=sqrt(s*(s-a)*(s-b)*(s-c));cout<<"三角形的面积为:"<<area;}elsecout<<"不能构成三角形!"<<endl;} ” 相关考题
考题
下列程序的运行结果为【】。 include void main(void) {int a=2,b=-1,c=2; if(a
下列程序的运行结果为【 】。include<iostream.h>void main(void){int a=2,b=-1,c=2;if(a<b)if(b<0)c=0;else c=c+1;cout<<c<<endl;}
考题
根据三角形的基本定理完成填空,则表达式为【 】。 include include void mai
根据三角形的基本定理完成填空,则表达式为【 】。include<iostream. h>include<math. h>void main(){double a,b,c,s,area;cout<<"请输入三角形三边a,b,c:"<<end1;cin>>a>b>>c;if(______){s=(a+b+c)/2;area=sqrt(s*(s-a)*(s-b)* (s-c)),cout<<"三角形的面积为:"<<area;}elsecout<<"不能构成三角形!"<<end1;}
考题
下列程序的执行结果是【 】。 include int a; int sum_a(void) { a=a+5; return a; }
下列程序的执行结果是【 】。include <iostream. h>int a;int sum_a(void){a=a+5;return a;}void main(void){a = a+sum_a();cout<<a<<endl;}
考题
以下程序的运行结果是______。 include include template class TA
以下程序的运行结果是______。include<iostream.h>include<math.h>template<class T>class TAdd//定义类模板TAdd,T为类型{Tx,y;public:TAdd (Ta,Tb) {x=a,y=b;) //构造函数Tadd() { retum x+y;}//成员函数};void main( ){TAdd<int>A (5,6);
考题
下列程序的输出结果是______。includeinclude using namespace std;void
下列程序的输出结果是______。include <iostream.h>include <cstring.h>using namespace std;void fun(const char*s,char C) {c=s[strlen (s)/2];}int main {){char str [] ="ABCDE";char ch=str[1];fun(str,sh);cout<<Ch;return 0;}
考题
在下列# include命令中,正确的一条是 ( )A.# include [string.h]B.# include {math.h}C.# include(stdio.h)D.# include<stdio.h>
考题
1、若程序中含有以下移位函数LED_PORT=_crol_(0xfe,1),则编程时必须包含以下哪条头文件()。A.#include <intrins.h>B.#include <stdio.h>C.#include <math.h>D.#include <absacc.h>
考题
【填空题】写出下面程序执行后的运行结果。 #include< iostream> using namespace std; # include <math.h> #define ROUND____ ____ ____*pow ____ + 0. 5) /pow ____) void main____ cout<<ROUND ____<< "," <<ROUND____; }
考题
若程序中含有以下移位函数LED_PORT=_crol_(0xfe,1),则编程时必须包含以下哪条头文件()。A.#include <absacc.h>B.#include <stdio.h>C.#include <intrins.h>D.#include <math.h>
热门标签
最新试卷