以下自定义数据类型的语句中,正确的是
A: A.Type student ID As String * 20 name As String * 10 age As Integer End student
B: B.Type student ID As String * 20 name As String * 10 age As Integer End Type
C: C.Type student ID As String name As String age As Integer End student
D: C.Type ID As String * 20 name As String * 10 age As Integer End Type student
A: A.Type student ID As String * 20 name As String * 10 age As Integer End student
B: B.Type student ID As String * 20 name As String * 10 age As Integer End Type
C: C.Type student ID As String name As String age As Integer End student
D: C.Type ID As String * 20 name As String * 10 age As Integer End Type student
举一反三
- 在窗体的通用声明段自定义了数据类型Students,下列____定义方式是正确的。 A: Public Type Students Name As String *10 StudNo As Integer End Type B: Type Students Dim Name As String *10 Dim StudNo As Integer End Students C: Type Students Name String *10 StudNo Integer End Type D: Private Type Students Name As String *10 StudNo As Integer End Type
- 以下能正确定义数据类型TelBook的代码是:____。 A: Type TelBook<br/>Dim Name As String * 10<br/>Dim TelNum As Integer End Type B: Type TelBook<br/>Name As String * 10<br/>TelNum As Integer End Type C: Type TelBook<br/>Name As String * 10<br/>TelNum As Integer End TelBook D: Type TelBook<br/>Name As String * 10<br/>TelNum As Integer End Type TelBook
- 以下能正确定义数据类型TelBook的代码是______。 A: A) Type TelBook B: Name As String*10 C: TelNum As Integer D: End Type E: B) Type TelBook F: Name As String*10 G: TelNum AS Integer H: End TelBook I: C) Type TelBook J: Name String*10 K: TelNum Integer L: End Type TelBook M: D) Typedef TelBook N: NameString*10 O: TelNum Integer P: EndType
- Student类中存在String类型name属性,下列Student类的构造方法中,哪个是正确的? A: Student(String name){} B: Student(String name) C: Student(name)() D: NewStudent (String name){}
- 【填空题】阅读程序写结果 public class Student { private static int sid = 0; private String name; int id; Student(String name) { this.name = name; id = sid++; } public void info() { System.out.println("My name is "+name+" No."+id); } public static void infoSta() { System.out.println(sid); } public static void main(String arg[]) { Student.sid = 100; Student st1 = new Student("huahua"); st1.sid = 2000; Student st2 = new Student("meimei"); st1.info(); st2.info(); } }