Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package main
- import "fmt"
- func main() {
- var dayFoodPrice, daySouvenirPrice, dayHotelPrice float64
- fmt.Scanln(&dayFoodPrice)
- fmt.Scanln(&daySouvenirPrice)
- fmt.Scanln(&dayHotelPrice)
- foodPrice := dayFoodPrice * 3
- souvenirPrice := daySouvenirPrice * 3
- hotelPrice := dayHotelPrice * 0.90 + dayHotelPrice * 0.85 + dayHotelPrice * 0.80
- transportPrice := 210.0 * 2 / 100 * 7 * 1.85
- fmt.Printf("Money needed: %.2f\n", foodPrice + souvenirPrice + hotelPrice + transportPrice)
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement