



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
Information about an exam for the advanced programming module of the bsc in business information systems degree at national university of ireland, galway. The exam took place during semester 1 of the academic year 2007/2008. It includes instructions, question prompts, and requirements for three programming questions, as well as examples of unix commands and javascript tasks. Intended for university students enrolled in the business information systems program.
Typology: Exams
1 / 6
This page cannot be seen from the preview
Don't miss anything!




Exam Code(s) 3BF
Exam(s) Third Year BSc in Business Information Systems
Module Code(s) MS
Module(s) Advanced Programming
Paper No. 1 Repeat Paper
External Examiner(s) Professor H. van der Heijden Internal Examiner(s) Professor J. F. Collins Dr. T. Acton
Instructions: (^) Answer any THREE QUESTIONS.
All questions carry equal marks.
Duration 2 hrs No. of Answer books
Requirements : Handout MCQ Statistical Tables Graph Paper Log Graph Paper Other Material No. of Pages 6 including this page Department(s) Accountancy and Finance
THIRD YEAR BSc. IN BUSINESS INFORMATION SYSTEMS EXAMINATION
(MS315) ADVANCED PROGRAMMING
Professor H. van der Heijden Professor J. F. Collins Dr. T. Acton
Time Allowed: TWO hours
Answer any THREE QUESTIONS. All questions carry equal marks.
An organisation wants a JavaScript program to determine the gross pay for each of its employees. The organisation pays ‘straight time’ for the first 39 weekly hours worked, and ‘time and a half’ for all extra hours worked. To test the program you have been provided with a list of employees, the number of hours each has worked in a particular week, and hourly rates for each employee (which may differ between employees). Your program should input these data for each employee and output an XHTML table showing each employee’s gross pay.
The partially completed script is provided below (you do not need to rewrite the provided code in your answer).
Q1: Employee Earnings
Click Refresh (or Reload) to run this script again.
(33.3 marks)
(c) Write Unix commands to accomplish each of the following tasks:
(i) List the contents of the current directory in long format, visually indicating whether content types are folders, executables, or text files. (ii) Pipe the contents of a file named ‘capture’ to the appropriate word count command to determine the file’s word count. (iii) Rename a file called ‘important’ to ‘not_really_important’. (iv) Change file permissions on a file named ‘stuff’ so that only the owner of the file can execute and write to it. (v) Create a folder called ‘backup’ as a copy of a non-empty folder called ‘docs’. (vi) Search for the text string ‘income’ in the file ‘taxes.txt’
(12 marks)
Describe some of the purposes and usage of each of the following technologies. In each case give a short example (in code) of a business- related implementation.
(a) Cascading Style Sheets (b) Perl (33.3 marks)
(a) A palindrome is a number or case-insensitive text phrase that reads the same backwards as forwards. For example, “ABBA”, “madam”, “able was I ere I saw elba”, 24542, 6770776, B2B and 7007 are all palindromes, whereas “Sligo beckons” is not. Using a language of your choice write a program or script that reads in a 3-digit integer and determines whether it is a palindrome. If the user enters anything other than a 3-digit integer, output a message to that effect using an information message dialog or other mechanism, and allow the user to enter a new value after dismissing this message.
(21.3 marks)
(b) Create an XML document to mark up the nutrition facts for a Christmas cake. A cake has a serving size of 10 servings, and the following nutritional value per serving: 400 calories, 21 grams of fat including 12 grams of saturated fat, 15 milligrams of cholesterol, 350 milligrams of Sodium, 90 grams of carbohydrate including 55 grams of sugar and 5.2 grams of fibre, and 8.5 grams of protein.
(12 marks)
The following PHP script queries a database. Separately in each case, explain what is occurring in those sections of code that are underlined in bold (these sections are numbered 1 to 6 below).
Search Results
" ); die( mysql_error() ); }** ?>
Mailing List Contacts
ID Last Name First Name E-mail Address Phone Number Fax
php
… continued