Forgotten password


Bulgarian    English


Report a bug !
Add search function to you browser

Powered by PHP Powered by MySQL
Pascal емулатор
1 member(s) online
Size control Print  Language: Pascal

Examples://Code arrange

To solve the problem you should shift the code with your mouse to end up with working solution.

Write a program which defines if the numbers X, Y and Z can be triangle sides.

  • write('Enter z=');
  • {
  • cout<<"z="; cin>>z;
  • (x+y>z) and (x+z>y) and (y+z>x) then write(‘Yes’)
  • double x, y, z;
  • cout<<"y="; cin>>y;
  • readln(y);
  • var x, y, z : real;
  • else write(‘No’)
  • end. #include<iostream.h>
  • }
  • if ((x>0)&&(y>0)&&(z>0)&& (x+y>z)&&(x+z>y)&&(y+z>x)) cout<<"Yes";
  • begin
  • write('Enter x=');
  • cout<<"x="; cin>>x;
  • readln(x);
  • if (x>0) and (y>0) and (z>0) and
  • write('Enter y=');
  • readln(z);
  • void main()
  • else cout<<"No";