Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package main
- import "fmt"
- func main() {
- var destination string
- fmt.Scanln(&destination)
- var budget, currentSum float64
- for ; destination != "End"; {
- fmt.Scanln(& budget)
- for ; budget > 0; {
- fmt.Scanln(¤tSum)
- budget -= currentSum
- }
- fmt.Printf("Going to %s!\n", destination)
- fmt.Scanln(&destination)
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement