Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
S.3 Computer Literacy (2011-2012) Practical Test (Second Test) Access Application – Set A [30M] There are many textbooks in the school library. Some book data are shown below: Name: Chinese Language Name: A-Level Biology ISBN: 978-0195962666 ISBN: 962!9906368 Publisher: Keys Chinese Publisher: Manhattan IsArts: Yes IsArts: No Name: English Language Name: Interactive Geography ISBN: 962-3043937 ISBN: 962-4697000 Publisher: Witman Publisher: Aristo IsArts: Yes IsArts: Yes Name: Information Technology Name: Chinese Literature ISBN: 978!9880033902 ISBN: 962-0404696 Publisher: Longman Publisher: China Book IsArts: No IsArts: Yes Name: Physics in life Name: New Way Chemistry ISBN: 978-0000040633 ISBN: 978-9882044678 Publisher: Longman Publisher: Manhattan IsArts: No IsArts: No 1. Create a database to store the above data. Store the database file as 3X_YY.accdb . 2M [X is your class and YY is your class number.] 2. Name the table as “textbook”. Define also the key field of the above data. 9M 3. The field order should be the same as above shown. 2M 4. Arrange in ascending order of ISBN. 5. Create the following 2 queries: (a) Display all data of Arts textbooks, sort by descending order of publisher. 2M 7M Name the query as “Arts” (b) Display names and ISBN in which ISBN starts with “978”, sort by ascending order of name. Name the query as “ISBN” 8M DO NOT TAKE AWAY AND DO NOT WRITE ANYTHING ON THIS PAPER S.3 Computer Literacy (2011-2012) Practical Test (Second Test) VB Application – Set A [30M] 1. Download the “setA.exe” at http://www.tanghin.edu.hk/~cl/s3/practical_test 2. Define i, ctime, neven, nodd, nzero, sum, cno As Integer 3. When the form loads, the following will happen: An input box is shown, asking for number of times to play (variable ctime) Randomize() is added here Set neven, nodd, nzero & sum to 0 4. When button1 is clicked, the following will happen: For I to run from 1 to ctime: A random integer between 1 and 20 is generated & stored in a variable cno cno is displayed in the listbox1 cno is added to the variable sum Depending on the value of cno, give response to the user: cno = 0 increase the value of variable nzero by 1 cno is divisible by 2 increase the value of variable neven by 1 not the above 2 cases increase the value of variable nodd by 1 Display the value of neven in textbox1 Display the value of nodd in textbox2 Display the value of nzero in textbox3 Display the value of sum in textbox4 Depending on the values of nzero, neven & nodd, give response to the user in a message box: (nzero greater than 0) or (neven greater than or equal to nodd) message: Zero numbers or more (or same) even numbers than odd numbers! not the above case message: No zero numbers and more odd numbers than even numbers! 5. You have to follow the design of the form shown in the program. 6. Pay attention to the responses, including: changes made at the prompt in msgbox/inputbox, changes made in the listbox. DO NOT TAKE AWAY AND DO NOT WRITE ANYTHING ON THIS PAPER