Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace exerciseSecondL{
- class exerciseSecondL{
- static void Main(){
- double x1 = double.Parse(Console.ReadLine());
- double y1 = double.Parse(Console.ReadLine());
- double x2 = double.Parse(Console.ReadLine());
- double y2 = double.Parse(Console.ReadLine());
- double width = Math.Abs(x2 - x1);
- double height = Math.Abs(y2 - y1);
- double areaPlane = width * height ;
- double perimeterPlane = 2*(width+height);
- System.Console.WriteLine(areaPlane);
- System.Console.WriteLine(perimeterPlane);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement