摘要:
package main import "fmt" //如果类名首字母大写,表示其他包也能够访问 type Hero struct { //如果说类的属性首字母大写, 表示该属性是对外能够访问的,否则的话只能够类的内部访问 Name string Ad int level int } /* func 阅读全文
摘要:
指针 package main import "fmt" /* func swap(a int ,b int) { var temp int temp = a a = b b = temp } */ func swap(pa *int, pb *int) { var temp int temp = 阅读全文
摘要:
2. Add Two Numbers 题目 You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each 阅读全文