Interface Programming CA (COMP6025) Exam, Cork Institute of Technology, Autumn 2011, Exams of Computer Programming

An examination paper from the cork institute of technology for the module interface programming ca (comp6025) in the bachelor of engineering in electronic engineering program. Instructions for a closed-book examination with both practical and theory sections. The practical section requires students to write console and windows-based visual basic.net programming projects. The theory section includes hand-written responses to questions related to pre-test and post-test while loops, dynamic array reallocation, user-defined data types, and sorting algorithms. The document also includes the names of the external and internal examiners, the percentage of the examination dedicated to practical and theory sections, and the duration and sitting of the examination.

Typology: Exams

2012/2013

Uploaded on 03/31/2013

parameshwari
parameshwari 🇮🇳

4.3

(7)

91 documents

1 / 5

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
CORK INSTITUTE OF TECHNOLOGY
INSTITIÚID TEICNEOLAÍOCHTA CHORCAÍ
Semester 1 Examinations 2010
Module Title: Interface Programming CA
Module Code: COMP6025
School: Electrical and Electronic Engineering
Programme Title: Bachelor of Engineering in Electronic Engineering
Programme Code: ELES_L7_Y2
External Examiner(s): Dr. A. Donnellan, Mr. I. Kennedy
Internal Examiner(s): Donal O’Donovan
Instructions: All questions must be answered
Practical Section: Console and Windows:
Using a PC with the Visual Basic.NET programming environment, complete
the exercises indicated. [Examination percentage: 45 %]
Instructions:
(a) Each program should be stored in a separate project folder. (Select the ‘Create
new folder’ option when creating the project.)
(b) The project name should be formatted as follows:
o ‘name question number’, e.g., John_Smith_Q1
(c) The final projects should be copied to a machine designated by the invigilator
at the end of the examination.
o It is the student’s responsibility to verify the correct transfer of the
project files to the invigilator’s machine.
(d) The VB.NET code for each program should also be printed off and inserted
into your answer book (see Theory Section). Your name and question number
should be clearly marked on each print-out page.
Theory Section:
A hand-written response is required for these questions.
[Examination percentage: 55 %]
Instructions:
All questions should be answered in answer book provided.
NOTE: This is a closed-book examination. Although, you may use the help supplied
by the Visual Basic programming environment, if you wish.
Duration: 2 hours
Sitting: Autumn 2011
pf3
pf4
pf5

Partial preview of the text

Download Interface Programming CA (COMP6025) Exam, Cork Institute of Technology, Autumn 2011 and more Exams Computer Programming in PDF only on Docsity!

CORK INSTITUTE OF TECHNOLOGY

INSTITIÚID TEICNEOLAÍOCHTA CHORCAÍ

Semester 1 Examinations 2010

Module Title: Interface Programming CA

Module Code: COMP

School: Electrical and Electronic Engineering

Programme Title: Bachelor of Engineering in Electronic Engineering

Programme Code: ELES_L7_Y

External Examiner(s): Dr. A. Donnellan, Mr. I. Kennedy Internal Examiner(s): Donal O’Donovan

Instructions: All questions must be answered

Practical Section: Console and Windows:  Using a PC with the Visual Basic.NET programming environment, complete the exercises indicated. [Examination percentage: 45 %]

Instructions: (a) Each program should be stored in a separate project folder. (Select the ‘Create new folder’ option when creating the project.) (b) The project name should be formatted as follows: o ‘name question number’, e.g., John_Smith_Q (c) The final projects should be copied to a machine designated by the invigilator at the end of the examination. o It is the student’s responsibility to verify the correct transfer of the project files to the invigilator’s machine. (d) The VB.NET code for each program should also be printed off and inserted into your answer book (see Theory Section). Your name and question number should be clearly marked on each print-out page.

Theory Section:  A hand-written response is required for these questions. [Examination percentage: 55 %] Instructions:  All questions should be answered in answer book provided.

NOTE: This is a closed-book examination. Although, you may use the help supplied by the Visual Basic programming environment, if you wish.

Duration: 2 hours

Sitting: Autumn 2011

Requirements for this examination:

Note to Candidates: Please check the Programme Title and the Module Title to ensure that you have received the correct examination paper. If in doubt please contact an Invigilator.

PC with Microsoft Visual Studio 2010 (or equivalent)

Practical Section - Windows:

2. Construct the user interface shown in Figure 1 using the Windows-based Visual Basic.NET programming project.

Figure 1

The user interface should operate as follows:

(a) When the form initially loads, set the ‘1 sec’ option to ‘selected’. [2 %]

(b) Text is entered in the textbox, located to the left of the ‘Add to Listbox’ button. Clicking the ‘Add to Listbox’ button should insert the typed text into the Listbox, ‘ListData’. [3 %]

(c) Clicking the ‘Flash Selected Text’ button should operate as follows: i. The timer should insert the text selected in the ListData listbox into ‘Display Label’. [4 %] ii. If no text is selected in ListData, a message box should appear informing the user to select text from the listbox first. [4 %] ii. Activate a timer initially set to 1 second. [2 %] iii. ‘Flash’ the ‘display label’ using alternate colours of your choice at the rate selected by the ‘half sec’ and ‘1 sec’ options. [4 %]

(d) Add a menu bar to your application with one menu called ‘File’ and insert an option to ‘Quit’ the program into the File submenu. [3 %]

Theory Section:

In an examination booklet, answer the following:

  1. (a) Explain the difference between a pre-test and post-test while loop. Using a simple example demonstrate the difference between the two variants. [6 %]

(b) i. Explain why dynamic array reallocation, using the ‘reDim’ command is a useful mechanism. Demonstrate how the first and second dimensions of a 2-dimensional (2-D) array may be resized from a size of 3 by 6 to a size of 7 by 15, respectively. [6 %]

ii. Write a function definition illustrating how a 2-D array may be passed as an argument to a function. The function should display each element of the 2-D array in turn. [8 %]

(c) i. Define a user-defined data type, called ‘structExp’, capable of storing a string, an integer and an array of 10 doubles. [5 %]

ii. Explain what must be done with the array of doubles in (c) i. to enable structExp to be used in a program. [3 %]

iii. Declare an array of structExp’s of size 100. Demonstrate how data may be inserted into each element of the 35th^ element of the array. [7 %]

(d) Using diagrams to illustrate your answer, give a detailed explanation of the operation of the ‘Selection Sort’ OR ‘Bubble Sort’ sorting algorithm. Use sample numbers to illustrate your answer. [20 %]

[55 %]