I want to use the values in the map I created to multiply with the days that are given by the input.
I just don't know how to scan for the values that are stored in the map.
package main
import "fmt"
func main() {
typeCar := map[string]int{
"audi": 50,
"volvo": 100,
"tesla": 300,
}
fmt.Print("how many days would you like to rent?: ")
var days int
fmt.Scanf("%d", &days)
fmt.Println("the price is:", typeCar["audi"]*days, "euro")
// "typeCar["audi"]" should be the input of the user instead.
}