Created
February 28, 2022 20:38
-
-
Save samueltcsantos/3fe86bb80ab292716bdf872e21cb0632 to your computer and use it in GitHub Desktop.
Calculando o dobro da área do quadrado em Go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
) | |
func main() { | |
var lado, area float32 | |
fmt.Print("Digite o comprimento do lado: ") | |
fmt.Scan(&lado) | |
area = lado * lado; | |
fmt.Println("Dobro da area é ", 2 * area) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Check out my page to see other examples Mais exemplos ...