Hi everyone, Hope you are all well. I've been struggling with Shorthand Variable Declaration in Go Lang.
Here is my code:*
package main
import "fmt"
func main() {
// full style variable declaration
var quantity int
// after confirming with user
quantity = 4
length, width := 1.4, 1.2
var customerName = "John Wick"
fmt.Println(customerName)
fmt.Println("has ordered", quantity, "towels")
fmt.Println("each with area of")
fmt.Println(length*width, "square feet")
}
*The code is saying line number 11 is the problem can anyone tell me what is wrong