Skip to content

Instantly share code, notes, and snippets.

@samueltcsantos
Last active March 4, 2022 01:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save samueltcsantos/75e34b8296b9fd3af16cc0305fdbfe60 to your computer and use it in GitHub Desktop.
Save samueltcsantos/75e34b8296b9fd3af16cc0305fdbfe60 to your computer and use it in GitHub Desktop.
package main
import (
"fmt"
)
func main() {
var numero int
fmt.Print("Digite um número inteiro: ")
fmt.Scan(&numero)
if numero % 2 == 0 {
fmt.Println(numero, " é Par")
} else {
fmt.Println(numero, "é Impar")
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment