using static System.Net.Mime.MediaTypeNames;
namespace HelloWorldFirst;
class Program
{
static void Main(string[] args)
{ int AmountOfNylon= int.Parse(Console.ReadLine());
int AmountOfPaint= int.Parse(Console.ReadLine());
int QuantityOfThinner= int.Parse(Console.ReadLine());
int HoursToWork = int.Parse(Console.ReadLine());
// Check if input is within the specified ranges
if (AmountOfNylon< 1 || AmountOfNylon> 100 || AmountOfPaint< 1 || AmountOfPaint> 100 || QuantityOfThinner< 1 || QuantityOfThinner> 30 || HoursToWork < 1 || HoursToWork > 9)
{
Console.WriteLine("Invalid input values. Please enter values within the specified ranges.");
}
else
{
// Calculate the final amount
double AmountMaterials = (AmountOfNylon+2) * 1.5 + AmountOfPaint * 1.1 * 14.5 + (QuantityOfThinner * 5) + 0.4;
double PriceHours = (AmountMaterials * 0.3) * HoursToWork;
double Amount = PriceHours + AmountMaterials;
// Output the result
Console.WriteLine(Amount);
}
}
}