feat: init & playaround
This commit is contained in:
22
go-by-example/constants/constants.go
Normal file
22
go-by-example/constants/constants.go
Normal file
@@ -0,0 +1,22 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"math"
|
||||
)
|
||||
|
||||
const s string = "constant"
|
||||
|
||||
func main() {
|
||||
fmt.Println(s)
|
||||
|
||||
const n = 500000000
|
||||
|
||||
const d = 3e20 / n
|
||||
|
||||
fmt.Println(d)
|
||||
|
||||
fmt.Println(int64(d))
|
||||
|
||||
fmt.Println(math.Sin(n))
|
||||
}
|
||||
Reference in New Issue
Block a user