Advertisement
Guest User

Untitled

a guest
Apr 18th, 2019
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.23 KB | None | 0 0
  1. public class Area{
  2. public static void main(String[] args){
  3. double a = 3.0;
  4. double b = 4.0;
  5. double c = 5.0;
  6. double s = 0.0;
  7. double area;
  8.  
  9. s = (a+b+c)/2;
  10. area = Math.sqrt(s*(s-a)*(s-b)*(s-c));
  11. System.out.println(area);
  12. }
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement