0

getting error in case 2 and 3

package main import "fmt" func main() { if temp := 99.5; temp <= 99.5 { fmt.Println("Allowed") } else { fmt.Println("Fever") } }

28th Jun 2021, 5:21 PM
Chinmay Anand
Chinmay Anand - avatar
4 odpowiedzi
+ 8
Try this then var temp float64 fmt.Scanln(&temp)
28th Jun 2021, 5:38 PM
Simba
Simba - avatar
+ 7
Your code needs to take the temp as input var temp int fmt.Scanln(&temp)
28th Jun 2021, 5:32 PM
Simba
Simba - avatar
+ 1
Thanks
28th Jun 2021, 7:16 PM
Chinmay Anand
Chinmay Anand - avatar
0
But question says ' Float'
28th Jun 2021, 5:35 PM
Chinmay Anand
Chinmay Anand - avatar