Advertisement
Guest User

Untitled

a guest
Oct 28th, 2016
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. program Noname31;
  2. var a,b,c : integer;
  3. temp, S : real;
  4. begin
  5. read(a,b,c);
  6. if (a+b>c)and(a+c>b)and(b+c>a)
  7. then
  8. begin
  9. writeln('Trikampi sudaryti galima');
  10. if (a=b)and(a=c)and(b=c)
  11. then writeln('trikampis lygiakrastis')
  12. else if (a=b)or(a=c)or(b=c)
  13. then writeln('trikampis lygiasonis')
  14. else writeln('trikampis ivairiakrastis');
  15. end;
  16. else writeln('trikampis nesudarys');
  17.  
  18.  
  19.  
  20. temp:=(a+b+c) / 2;
  21. s:=(temp-a)*(temp-b)*(temp-c); s:=s*temp; s:=sqrt(s);
  22. writeln('plotas: ', s:5:3);
  23. Readln(a);
  24. end.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement