Skip to content

Instantly share code, notes, and snippets.

@samueltcsantos
Created February 28, 2022 18:52
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/35f5d484999818cff1fe5e5080f7c389 to your computer and use it in GitHub Desktop.
Save samueltcsantos/35f5d484999818cff1fe5e5080f7c389 to your computer and use it in GitHub Desktop.
Lendo dois números e exibindo a soma.
package main
import (
"fmt"
)
func main() {
var numero1 int
var numero2 int
fmt.Print("Digite o primeiro número: ")
fmt.Scan(&numero1)
fmt.Print("Digite o segundo número: ")
fmt.Scan(&numero2)
fmt.Println("A soma é ", numero1 + numero2)
}
@samueltcsantos
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment