Welcome! Log In Create A New Profile

Advanced

Past exam questions

Posted by Reanie 
Announcements Last Post
Announcement SoC Curricula 09/30/2017 01:08PM
Announcement Demarcation or scoping of examinations and assessment 02/13/2017 07:59AM
Announcement School of Computing Short Learning Programmes 11/24/2014 08:37AM
Announcement Unisa contact information 07/28/2011 01:28PM
avatar Past exam questions
November 06, 2009 06:36PM
I had a bit of time and compared the exam questions given from 2004 - now. Most are exactly the same, but in 2004 and 2007 there were a few different questions / variables. I list them below - not nicely edited, sorry.

Quote

QUESTION 2 (2004) [10]
Consider the following pre-emptive priority-scheduling algorithm based on dynamically changing priorities:
Do While (jobs in ready queue)
Start the job with the numerically highest priority;
If (end of quantum or request for I/O) then
Suspend the job currently running;
Add 'alpha' to the priority of each waiting job;
Add 'beta' to the priority of the job that has just been running
End_If
Accept any new jobs into the ready queue with priority 0
End_Do

If the number of jobs in the ready queue is n, discuss the scheduling algorithms that result from each of the following settings of 'alpha' and 'beta':
2.1 'alpha' < 'beta' < 0 (3)
2.2 'beta' > 0 and 'alpha' = 'beta'/n (3)
2.3 'alpha' = 'beta'/(n + 1) and 'beta' = (1 - n) (4)

QUESTION 3 (2004) [18]
Consider the following set of processes with arrival times, length of the
CPU-burst times (in milliseconds) and priorities below:
Process : Arrival time : Burst time : Priority
P1 : 0 : 4 : 2
P2 : 3 : 1 : 1
P3 : 4 : 9 : 2
P4 : 10 : 2 : 4
P5 : 12 : 4 : 3
P6 : 13 : 3 : 4
Assume that a smaller priority number indicates a higher priority.

3.1 Draw three GANTT charts, each showing the execution of these processes over time for each of the following scheduling algorithms: (8)
(a) Shortest Job First (SJF) without pre-emption
(b) A non-pre-emptive priority algorithm
(c) Round Robin with the quantum set to 2 /
NOTE: Apply the following two (2) principles when calculating the GANTT chart for Round Robin:
(1) A new job that enters the system is placed at the back of the ready queue, taking its place after the jobs already waiting to execute.
(2) A new job which enters the system for the first time is given preference over a job that has just finished executing a quantum. Such a new job will still be placed at the back of the ready queue, but ahead of a job which is also placed at the back of the queue after finishing a time quantum.
3.2 Give formulas for the turnaround time and waiting time of a process and then use these formulas to calculate the turnaround time and the waiting time for each process under each of the algorithms in 3.1 above. Show all your calculations clearly. (8)
3.3 Calculate which one of the schedulers in 3.1 above results in the minimal average waiting time over all the processes. Again, show all your calculations clearly. (2)

QUESTION 4 (2004) [15]
A particular system uses the deadlock avoidance approach. At time t0 the system state is:
Process : Allocation : Max : Available
P0 : 1 0 0 4 : 1 6 5 6 : 1 5 2 0
P1 : 1 4 2 2 : 2 4 5 7 :
P2 : 0 0 1 2 : 0 0 1 2 :
P3 : 0 2 1 0 : 1 7 5 0 :
P4 : 0 6 3 2 : 0 6 5 2 :
4.1 Give formulas to calculate the Need array as well as the maximum resource vector. (2)
4.2 Use your formulas in 4.1 above to calculate the contents of the array Need as well as the content of the maximum resource vector. (3)
4.3 Determine whether the system is in a safe state by trying to calculate a safe sequence. Show all workings clearly. (8)
4.4 Suppose a request from process P0 arrives for (0, 5, 3, 0). Determine whether the request may be safely granted or not. Show all workings clearly. (2)

QUESTION 3 (2007) [13]
A particular system uses the deadlock avoidance approach. At time t0 the system state is:
Process : Allocation : Need : Available
P0 : 3 0 1 1 : 1 1 0 0 : 1 0 2 0
P1 : 0 1 0 0 : 0 1 2 2 :
P2 : 1 1 1 0 : 3 1 0 0 :
P3 : 1 1 0 1 : 0 0 1 0 :
P4 : 0 0 0 0 : 2 1 1 0 :
3.1 Calculate the contents of the array Max as well as the content of the maximum resource vector. (3)
3.2 Determine whether the system is in a safe state by trying to calculate a safe sequence. Show all workings clearly. (8)
3.3 Suppose a request from process P2 arrives for (2, 0, 0, 0). Determine whether the request may be safely granted or not. Show all workings clearly. (2)

QUESTION 5 (2004)
Similar to Question 4.2 in our exam tut, but with sequence of page references given as:
b, c, e, h, c, f, i, c, g, c, b, c, e, b

QUESTION 7 (2007)
Similar to Question 6 in our exam tut, but with 50 blocks and block 26 in the middle.

QUESTION 6 (2004) [10]
Segmentation is similar to paging, but uses variable-sized segments instead of fixed-sized pages. Define two segment-replacement algorithms based on the FIFO and LRU page replacement schemes. Remember that since segments are of different sizes, the segment that is chosen to be replaced may not be big enough to leave enough consecutive memory locations for the new segment to be loaded. Consider suitable strategies for systems where segments cannot be relocated and for systems where they can be relocated.
Write your 2 algorithms in a suitable block-structured pseudocode language (e.g. Pascal-, C-, or Java-like pseudo code).

QUESTION 7 (2004) [15]
Write a well-planned essay in which you name and discuss the three (3) common routing schemes used to route messages through a network.
Build your essay around the following topics:
(a) the names of the 3 schemes.
(b) how each of these schemes work.
(c) the advantages, disadvantages and problems of each scheme.
(d) the best scheme of the three with justification.
Note: Any good essay starts with an Introduction, followed by the Body and ends with a sensible Conclusion.

QUESTION 8 (2004) [7]
Consider the Banker's resource-request algorithm below:

1. If Requesti <= Needi
then proceed to step 2.
Else Error.
2. If Requesti <= Available
then proceed to step 3.
Else Wait.
3. Allocate requested resources
to process Pi by
modifying the state as follows:
Available := Available -
Requesti;
Allocationi := Allocationi +
Requesti;
Needi := Needi - Requesti;

Let n be the number of processes in the system and m be the number of resource types. Prove that the algorithm given above requires an order of mn operations (i.e. complexity is O(mn)).
Re: Past exam questions
November 06, 2009 07:31PM
Please can you post the past exams and tut letter 102's to cramming10@gmail.com

thx
avatar Re: Past exam questions
November 06, 2009 08:37PM
Done
Re: Past exam questions
November 07, 2009 06:34AM
Hi Reanie,

Please can you send the past exams to 35594691@mylife.unisa.ac.za.

Much appreciated.
avatar Re: Past exam questions
November 07, 2009 08:55AM
Done
Re: Past exam questions
November 07, 2009 09:29AM
Hi Reanie, thanks for sharing.. have you had a chance to look at the Ass 2 qst i posted previously - just need to know if i'm going mad or what - if i look at previous tuts, it's worked out a different way and it looks to me like the tut in 2009 is incorrect.

Would appreciate your thoughts on this..
RC
Re: Past exam questions
November 09, 2009 10:31AM
Hi there,

Can one of you guys please send me the past year exams and tut letters. raven.chetty@gmail.com

Thanks alot and good luck for tomorrow

Raven
Re: Past exam questions
November 09, 2009 12:25PM
Hey RC.
Check your mail for past exam papers that Reanie sent me. All you guys, good luck for tomorrows exam!
avatar Re: Past exam questions
November 09, 2009 02:19PM
@RC - you've now got 2 copies...
Re: Past exam questions
November 09, 2009 02:37PM
I really do think that we only have to concentrate on tut102 and the practical questions in assignment 1 and 2...
Re: Past exam questions
November 09, 2009 04:18PM
fran13 Wrote:
-------------------------------------------------------
> I really do think that we only have to concentrate
> on tut102 and the practical questions in
> assignment 1 and 2...

I hope so...
Re: Past exam questions
November 10, 2009 07:52AM
Going through your past exam qsts, where do we find the answers for Qst 2 and Qst 8?
Ok, now i'm panicking! confused smiley
avatar Re: Past exam questions
November 10, 2009 08:32AM
I haven't worked out the answers either.
Question 2 is similar to Exercise 6.3 in Tut 501.
Banker's algorithm is in Ch 7.5.3 and is reference in Tut 501.

[Edit - Add]
We handled Quesion 2 to in Question 6 of Assignment 1 and Banker in Question 2 of Assignment 2.
Re: Past exam questions
November 10, 2009 09:12AM
Thanks! will check it out..

Good luck to everybody!
avatar Re: Past exam questions
November 10, 2009 10:10AM
@Annie - although we've had the Banker's algorithm, we didn't have anything like the Q8 - can't find anything about that sort of question - hopefully we won't be getting it.
Re: Past exam questions
November 10, 2009 10:16AM
Hope so too.. what gets me is the paper is now 2 hours, but still 7 questions - i was sure they wouldn't ask the theory question at the end - already counts for 20%, but who knows - will find out in couple of hours ugh!
Re: Past exam questions
November 10, 2009 10:24AM
Can't wait to funish this one today, but still, 3 exams left for me, including cos311-4! (Eish!!)
Re: Past exam questions
February 20, 2010 10:54PM
Hi Reanie,
could you please mail me the exam papers as well. Do you also have the answers? Thak you very so much. My email is : talented@t-online.de

cheers
Kübra
Re: Past exam questions
October 08, 2010 02:49PM
Where can I get past exam questions for ICT2613???Anybody...
Re: Past exam questions
November 13, 2010 01:09PM
Hi, Reanie. Would you be able to email me previous exam papers on COS311 and maybe any previous assignments with memorandums if possible? I will be registering for 2011. Would really appreciate it. My email: birds@absamail.co.za Many thanks.
Re: Past exam questions
December 21, 2010 03:27PM
yeshmeeta@yahoo.co.uk
Hi, please send me the tuts, exam papers etc! many thanks! smiling smiley
Sorry, only registered users may post in this forum.

Click here to login