Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package main
- import "fmt"
- func main() {
- var numberCount, number int
- fmt.Scanln(&numberCount)
- var sumNumbers = 0
- for i := 0; i < numberCount; i++ {
- fmt.Scanln(&number)
- sumNumbers += number
- }
- fmt.Printf("%.2f\n", float64(sumNumbers) / float64(numberCount))
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement