using System; using System.Collections; using System.Collections.Generic; using System.Linq; using System.Text; using System.Text.RegularExpressions; namespace c编程练习题 { class Program { public struct student //结构体的用法. { public int code; public string
Class class Person{ var age = 22, name = "frank" func growolder() { self.age++ //++ 要跟住 不要乱打空格 // 如果是var 可以在结构体内部进行修改 } } func celebrationBirthday(person:Person) { print("生日快乐 (\(person.name))") person.growolder() } let Frank = Person(