摘要:
package main import ( "fmt" "os" //"MyProject/pingguoxueyuan/gostudy/listen13/homework/student_mgr" ) // 把下面这个结构体和函数注释了就不能单独go run 运行了,要go build才能把2个文 阅读全文
摘要:
package main import ( "fmt" ) type Address struct { Province string City string CreateTime string } type Email struct { Account string CreateTime stri 阅读全文
摘要:
package main import ( "fmt" ) type User struct { Username string Sex string Age int int string } type Address struct { Province string City string } t 阅读全文
摘要:
package main import "fmt" func test1() { var a interface{} // 空接口可以实现任何类型的变量 var b int =100 a = b fmt.Printf("test1 00> %T %v \n",a,a) var c string = 阅读全文
摘要:
package main import("fmt") type Programer struct { name string base float32 extra float32 } func (p Programer) CalcSalary() float32 { return p.base } 阅读全文
摘要:
package main import ( "fmt" "io" "net/http" ) func main(){ //获取服务器应答包内容 resp,err := http.Get( "http://www.baidu.com") if err != nil { fmt.Println( "ht 阅读全文
摘要:
package main import ( "fmt" "net/http" "os" ) func OpenSendFile(fName string, w http.ResponseWriter) { //pathFileName := "C:/itcast/test" + fNmae path 阅读全文
摘要:
https://blog.csdn.net/flyfreelyit/article/details/80281467 https://blog.csdn.net/qq_27295403/article/details/110469972 https://blog.csdn.net/qq_290611 阅读全文