In the following Go code snippet,
var i int = 5
for ; i >= 0; i-- {
fmt.Println(i)
}What changes would you make to create a countdown from 10 to 1 and print "Liftoff!" when the countdown ends?
In the following Go code snippet,
var i int = 5
for ; i >= 0; i-- {
fmt.Println(i)
}What changes would you make to create a countdown from 10 to 1 and print "Liftoff!" when the countdown ends?
Create a free account to access the full topic