2024-05-14 20:53:13 +08:00
|
|
|
package main
|
|
|
|
|
|
|
|
|
|
import (
|
2025-04-03 15:52:18 +08:00
|
|
|
"github.com/goplus/lib/c"
|
|
|
|
|
"github.com/goplus/lib/py"
|
|
|
|
|
"github.com/goplus/lib/py/statistics"
|
2024-05-14 20:53:13 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
|
|
func main() {
|
2024-05-16 00:02:10 +08:00
|
|
|
list := py.List(1.0, 2.0, 3.0, 4.0, 4.0)
|
2024-05-14 20:53:13 +08:00
|
|
|
mean := statistics.Mean(list)
|
|
|
|
|
c.Printf(c.Str("mean(1, 2, 3, 4, 4) = %f\n"), mean.Float64())
|
|
|
|
|
}
|