


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
This document consists of exam questions for a bachelor of engineering in electronic engineering course, specifically for the computer applications & programming module. The questions cover various topics including basic programming, vb controls, program development stages, and networking. Students are required to answer any five questions, each carrying equal marks. The document also includes instructions for examiners and examples for some questions.
Typology: Exams
1 / 4
This page cannot be seen from the preview
Don't miss anything!



Answer ANY five questions. All questions carry equal marks.
Examiners: Mr. D. O’Donovan Mr. D. Denieffe Dr. P. O’Sullivan
(a) Generate 100 random integer numbers between 56 and 83 inclusive and store the numbers in a 2-D array consisting of 10 rows and 10 columns. [5 %]
(b) Calculate the average of each row of the array in (a) and store the results in an appropriate array called ‘results’. [5 %]
(c) Write the contents of the array in (a) above to a file called “testdata.dat” in the root directory of the D drive. [5 %]
(d) Write a function to calculate the average (called ‘ArrayAverage’) of the results array in (b). The array and its size should be passed as arguments to the function. The average result should be passed back to the calling routine such that the function ‘ArrayAverage’ may be used in the following manner: average = ArrayAverage(results) [5 %]
Control [2 %] Menu Editor [2 %] (b)Write a program to: i. Update the system time (use the TIME$ function) at the top-left corner of a program form after the period selected via the menu option. The menu offers 3 possible time intervals 30, 60 and 90 seconds respectively (see Figure 2.1). State as timer interval settings used. [7 %] ii. The location of any mouse-clicks should be written to a listbox as a string consisting of x-coordinate/y-coordinate. [4 %] iii. Every second mouse-click should increment a counter called ‘update’ located in the top- right of the program form in (b) i. [5 %]
Figure 2.
(b) In the context of connecting to the Internet, where might the following technologies be employed? o Satellite [2%] o Wireless [3%] o ADSL [3%] o Fiber-Optics [2%]
(b) Write a function/subroutine, which reads the file contents into this array. [8 %]
(c) Write a function/subroutine, which takes an input voltage value, finds the matching element in the array and returns the correct output value. [8 %]