Write a program that will help people who are going on vacation. The program should calculate the total required sum (e.g. $) of money to have a good rest for a given duration.
There are four parameters that have to be considered:
- duration in days
- total food cost per day
- one-way flight cost
- cost of one night in a hotel (the number of nights is equal to the duration of days minus one)
Read integer values of these parameters from the standard input and then print the result.
Do not forget to consider the flight back!