using System;
public class DoubleValue
{
public static void Main(string[] args)
{
double a = Convert.ToDouble(Console.ReadLine());
double b = Convert.ToDouble(Console.ReadLine());
double perimeter = a * 2 + b * 2;
double area = a * b;
double diagonal = Math.Sqrt(a * a + b * b);
Console.WriteLine("Perimeter: {0}", perimeter);
Console.WriteLine("Area: {0}", area);
Console.WriteLine("Diagonal: {0}", diagonal);
}
}