作者sky810675 (KKMAN)
看板TransCSI
标题[问题] array问题
时间Mon May 11 21:16:10 2009
considering an array of record student[40], each record has three fields,
namely, student, name, and score. if the data types of studentid, name,
and score are integer (4 bytes), string (8 bytes), and short integer (2 bytes)
respectively, please answer the following questions.
1.how many bytes in total are needed to store students?
a. 560
b. 40
c. 14
d. 160
2.if studentid[1] is stored in memory starting at loocation 1000 and the unit
of memory location is byte, what is the staring address of students[10]?
a. 1140
b. 1010
c. 1009
d. 1126
答案1.A
2.D
可以麻烦知道的人讲解一下为什麽吗??谢谢罗
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.128.20.177
1F:→ RJking:1. (4+8+2)*140 05/12 00:35