Kingdom of Saudi Arabia
Ministry of Education
Prince Sattam Bin Abdulaziz University وزارة اﻟﺘﻌﻠﯿﻢ
College of Computer ﺟﺎﻣﻌﺔ اﻻﻣﯿﺮ ﺳﻄﺎم ﺑﻦ ﻋﺒﺪ اﻟﻌﺰﯾﺰ
Engineering and sciences ﻛﻠﯿﺔ ھﻨﺪﺳﺔ وﻋﻠﻮم اﻟﺤﺎﺳﺐ
Department of Computer Sciences ﻗﺴﻢ ﻋﻠﻮم اﻟﺤﺎﺳﺐ
Course Title and Code:
Data Structures and Algorithms, CS2321
: اﻟﻄﺎﻟﺒﺔ/اﺳﻢ اﻟﻄﺎﻟﺐ
First Exam 1
Instructor Name:Dr. Mahdi Khemakhem
Semester I :اﻟﺮﻗﻢ اﻟﺠﺎﻣﻌﻲ
& Mrs Jabeen Hussain
1438/1439
Date: November 7, 2017
:رﻗﻢ اﻟﺸﻌﺒﺔ
Time: 60 minutes
Instructions ﺗﻌﻠﯿﻤﺎت
ﺻﻔﺤﺎت5 ( اﺳﺌﻠﺔ ﻋﻠﻰ5 ) ھﺬا اﻻﺧﺘﺒﺎر ﻣﺆﻟﻒ ﻣﻦ §
§ This exam consists of 5 questions 5 pages. ﺟﺎوب ﻋﻠﻰ ﺟﻤﯿﻊ اﻷﺳﺌﻠﺔ ﻋﻠﻰ ﻧﻔﺲ اﻻوراق §
§ All questions should be answered on the same sheets
§ Electronic devices that could have a memory is not
ﯾﻤﻨﻊ اﺳﺘﻌﻤﺎل اﻻﺟﮭﺰة اﻻﻟﻜﺘﺮوﻧﯿﺔ اﻟﺘﻲ ﺗﺤﺘﻮي ﻋﻠﻰ ذاﻛﺮة §
allowed (ﯾﺴﻤﺢ ﺑﺎﺳﺘﻌﻤﺎل اﻻﻟﺔ اﻟﺤﺎﺳﺒﺔ )دون ذاﻛﺮة §
§ Traditional calculator is allowed .ﯾﺠﺐ اﻻﻟﺘﺰام ﺑﺠﻤﯿﻊ ﻗﻮاﻧﯿﻦ وﻟﻮاﺋﺢ اﻻﻣﺘﺤﺎﻧﺎت §
§ Examination rules must be adhered. ﻻ ﯾﺴﻤﺢ ﺑﺎﻟﻜﺘﺐ أو اﻟﻤﻮاد ذات اﻟﺼﻠﺔ داﺧﻞ ﻏﺮﻓﺔ اﻻﻣﺘﺤﺎن §
§ Books or other related materials are NOT allowed اﻟﻜﺘﺎﺑﺔ ﺗﻜﻮن ﺑﺎﻟﻘﻠﻢ اﻷزرق ﻓﻘﻂ §
§ Use blue pen only
For Official Use Only
First Marking Second Marking
Course Max Obtained Instructor’s Obtained
Question No. Second Signature
Outcome Marks Marks Signature Marks
Q1 CLO#1 6
Q2 CLO#3 2
Q3 CLO#5 2
Q4 CLO#4 2.5
Q5 CLO#2 2.5
Total Marks 15
Total Marks in words
1. Dr. Mahdi Khemakhem.
Name of Instructors
2. Mrs. Jabeen Hussain
Name of Peer-Reviewer
Data Structures and Algorithms, CS2321– First Exam, Semester 1, 2017/2018 Page: 1 of 5
, Q. 1: I need to know the technical words - أﺣﺘﺎج إﻟﻰ ﻣﻌﺮﻓﺔ اﻟﻜﻠﻤﺎت اﻟﺘﻘﻨﯿﺔ (6.25 marks)
@Fill in the blanks using the following words:
function first factors last
problem analytical mapped time
precedes follows instructions predecessor
successor linked empirical speed
doubly memory objects operations
growth-rate data-structures operating-system dynamic-memory
1. An algorithm is a clearly specified ordered set of simple instructions to be followed to solve a
problem.
2. Computing time and memory space are two important resources in algorithm analysis
process.
3. The choice of the data-structures can affect the complexity of an algorithm.
4. The algorithm performance is usually computed either by empirical method or analytical
method.
5. To compare two algorithms using theoretical method, each algorithm is mapped to a
mathematical function. Then the functions are compared in terms of their growth-rate to
decide which is better.
6. The algorithm analysis using experimental method is not feasible because when running a
program on a computer there are some factors that affect the speed of running such as: CPU,
operating-system, Compiler.
7. Abstract Data Types (ADT) is defined by a set of objects and a set of operations.
8. Let a list of 7 elements A1, A2, A3, A4, A5, A6, A7. We say that:
a. A1 is the first element.
b. A7 is the last element.
c. A2 precedes A3 and A3 follows A2.
d. A6 is the successor of A5 and A5 is the predecessor of A6.
9. Array, circular linked List, doubly linked list are three standard implementations for the list
ADT.
10. Many programming language enables programmer to control the allocation and deallocation
of memory. This is known as dynamic-memory management.
Data Structures and Algorithms, CS2321– First Exam, Semester 1, 2017/2018 Page: 2 of 5
Ministry of Education
Prince Sattam Bin Abdulaziz University وزارة اﻟﺘﻌﻠﯿﻢ
College of Computer ﺟﺎﻣﻌﺔ اﻻﻣﯿﺮ ﺳﻄﺎم ﺑﻦ ﻋﺒﺪ اﻟﻌﺰﯾﺰ
Engineering and sciences ﻛﻠﯿﺔ ھﻨﺪﺳﺔ وﻋﻠﻮم اﻟﺤﺎﺳﺐ
Department of Computer Sciences ﻗﺴﻢ ﻋﻠﻮم اﻟﺤﺎﺳﺐ
Course Title and Code:
Data Structures and Algorithms, CS2321
: اﻟﻄﺎﻟﺒﺔ/اﺳﻢ اﻟﻄﺎﻟﺐ
First Exam 1
Instructor Name:Dr. Mahdi Khemakhem
Semester I :اﻟﺮﻗﻢ اﻟﺠﺎﻣﻌﻲ
& Mrs Jabeen Hussain
1438/1439
Date: November 7, 2017
:رﻗﻢ اﻟﺸﻌﺒﺔ
Time: 60 minutes
Instructions ﺗﻌﻠﯿﻤﺎت
ﺻﻔﺤﺎت5 ( اﺳﺌﻠﺔ ﻋﻠﻰ5 ) ھﺬا اﻻﺧﺘﺒﺎر ﻣﺆﻟﻒ ﻣﻦ §
§ This exam consists of 5 questions 5 pages. ﺟﺎوب ﻋﻠﻰ ﺟﻤﯿﻊ اﻷﺳﺌﻠﺔ ﻋﻠﻰ ﻧﻔﺲ اﻻوراق §
§ All questions should be answered on the same sheets
§ Electronic devices that could have a memory is not
ﯾﻤﻨﻊ اﺳﺘﻌﻤﺎل اﻻﺟﮭﺰة اﻻﻟﻜﺘﺮوﻧﯿﺔ اﻟﺘﻲ ﺗﺤﺘﻮي ﻋﻠﻰ ذاﻛﺮة §
allowed (ﯾﺴﻤﺢ ﺑﺎﺳﺘﻌﻤﺎل اﻻﻟﺔ اﻟﺤﺎﺳﺒﺔ )دون ذاﻛﺮة §
§ Traditional calculator is allowed .ﯾﺠﺐ اﻻﻟﺘﺰام ﺑﺠﻤﯿﻊ ﻗﻮاﻧﯿﻦ وﻟﻮاﺋﺢ اﻻﻣﺘﺤﺎﻧﺎت §
§ Examination rules must be adhered. ﻻ ﯾﺴﻤﺢ ﺑﺎﻟﻜﺘﺐ أو اﻟﻤﻮاد ذات اﻟﺼﻠﺔ داﺧﻞ ﻏﺮﻓﺔ اﻻﻣﺘﺤﺎن §
§ Books or other related materials are NOT allowed اﻟﻜﺘﺎﺑﺔ ﺗﻜﻮن ﺑﺎﻟﻘﻠﻢ اﻷزرق ﻓﻘﻂ §
§ Use blue pen only
For Official Use Only
First Marking Second Marking
Course Max Obtained Instructor’s Obtained
Question No. Second Signature
Outcome Marks Marks Signature Marks
Q1 CLO#1 6
Q2 CLO#3 2
Q3 CLO#5 2
Q4 CLO#4 2.5
Q5 CLO#2 2.5
Total Marks 15
Total Marks in words
1. Dr. Mahdi Khemakhem.
Name of Instructors
2. Mrs. Jabeen Hussain
Name of Peer-Reviewer
Data Structures and Algorithms, CS2321– First Exam, Semester 1, 2017/2018 Page: 1 of 5
, Q. 1: I need to know the technical words - أﺣﺘﺎج إﻟﻰ ﻣﻌﺮﻓﺔ اﻟﻜﻠﻤﺎت اﻟﺘﻘﻨﯿﺔ (6.25 marks)
@Fill in the blanks using the following words:
function first factors last
problem analytical mapped time
precedes follows instructions predecessor
successor linked empirical speed
doubly memory objects operations
growth-rate data-structures operating-system dynamic-memory
1. An algorithm is a clearly specified ordered set of simple instructions to be followed to solve a
problem.
2. Computing time and memory space are two important resources in algorithm analysis
process.
3. The choice of the data-structures can affect the complexity of an algorithm.
4. The algorithm performance is usually computed either by empirical method or analytical
method.
5. To compare two algorithms using theoretical method, each algorithm is mapped to a
mathematical function. Then the functions are compared in terms of their growth-rate to
decide which is better.
6. The algorithm analysis using experimental method is not feasible because when running a
program on a computer there are some factors that affect the speed of running such as: CPU,
operating-system, Compiler.
7. Abstract Data Types (ADT) is defined by a set of objects and a set of operations.
8. Let a list of 7 elements A1, A2, A3, A4, A5, A6, A7. We say that:
a. A1 is the first element.
b. A7 is the last element.
c. A2 precedes A3 and A3 follows A2.
d. A6 is the successor of A5 and A5 is the predecessor of A6.
9. Array, circular linked List, doubly linked list are three standard implementations for the list
ADT.
10. Many programming language enables programmer to control the allocation and deallocation
of memory. This is known as dynamic-memory management.
Data Structures and Algorithms, CS2321– First Exam, Semester 1, 2017/2018 Page: 2 of 5