package main
import"fmt"funcmain(){/*
常量:
1.概念:同变量类似,程序执行过程中数值不能改变
2.语法:
显式类型定义
隐式类型定义
3.常数
固定的数值:100,“abc”
*/const path string="100"const pi =3.14const c1,c2,c3 =100,3.14,"hah"const(
male =0
female =1
unknow =3)const(
a int=100
b
c string="man"
d
e
)
fmt.Printf("%T,%d\n",a,a)
fmt.Printf("%T,%d\n",a,b)
fmt.Printf("%T,%d\n",a,c)
fmt.Printf("%T,%d\n",a,d)
fmt.Printf("%T,%d\n",a,e)const(
SPRING=0
SUMMER=1
AUTUME=2
WINTER=3)}