- 1

Please what am i missing

package main import "fmt" func main() { //your code goes here var num int fmt.Scanln(&num) if num==1{ fmt.Println ("One") } else if num==2{ fmt .Println ("Two") } else if num==3{ fmt.Println ("Three") } else if num==4{ fmt.Println ("Four") } else if num ==5{ fmt.Println ("Five") } else if num==6{ fmt.Println ("Six") } else if num ==7{ fmt.Println ("Seven") } else if num ==8{ fmt.Println ("Eight") } else if num==9{ fmt.Println ("Nine") } else if num==10{ fmt.Println ("Ten") }else { fmt.Println ("zero") } }

15th Jun 2021, 4:13 AM
Cyber DeCypher 🐎
Cyber DeCypher 🐎 - avatar
4 Answers
+ 4
Is: Zero
15th Jun 2021, 4:17 AM
Cmurio
Cmurio - avatar
+ 3
The same is supposed to be 3 numbers, so you must repeat that code 2 more times
15th Jun 2021, 4:18 AM
Cmurio
Cmurio - avatar
0
Destiny Simon Change all elif if statements like this↓ if num==1{ fmt.Println ("One") }else if num==2{ fmt .Println ("Two") }else if num==3{ fmt.Println ("Three") }else if num==4{ fmt.Println ("Four") }else if num ==5{ fmt.Println ("Five") }else if num==6{ fmt.Println ("Six") }else if num ==7{ fmt.Println ("Seven") }else if num ==8{ fmt.Println ("Eight") }else if num==9{ fmt.Println ("Nine") }else if num==10{ fmt.Println ("Ten") }else { fmt.Println ("zero") }
15th Jun 2021, 5:31 AM
˜”*°•.˜”*°• Mohan 333 •°*”˜.•°*”˜
˜”*°•.˜”*°• Mohan 333 •°*”˜.•°*”˜ - avatar
- 1
15th Jun 2021, 4:37 AM
Cyber DeCypher 🐎
Cyber DeCypher 🐎 - avatar