You are on page 1of 2

Bahria University, Islamabad Campus

Department of Computer Science


Final Assessment
Class/Section: BSCS 1A/1B
(Spring 2020 Semester)

Computer Programming Date/Time Assigned:2/7/2020 (10am)


Course Code: csc-113 Submission Date/Time: 2/7/2020(6pm)
Faculty’s Name: Mahwish Pervaiz Max Marks: 50

INSTRUCTIONS:

I. All questions are mandatory. Give proper screen shot of code and program execution.

Student Name: Enrollment No.

Question # 1

Write a program that reverses the 2D matrix column wise using user defined function. [10]
2 3 5 6
22 33 44 66
12 34 65 65
56 65 45 34

Question # 2

1. Write the limitation of Default arguments. Write in your own words [4].
2. Write the scenario of best usage of
 pointers [2]
 function overloading [2]
 Call function by Reference [2]

Question # 3
 Create a structure date of fields Day, month and year. [1]
 Create structure Project with fields ProjId, ProjName, StartDate of type Date.[2]
 Create another structure Developer with fields Developer Id, Developer Name and
Year of experience and CurrentProject of type Project. [2]

Page 1 of 2
Enrollment Number: ____________________________

 Create a menu in main function that ask user to enter choice: [2]
o 1 for addition of new record
o 2 for updation of record
o 3 for search record
o 4 for Writing Data in File
o 5 For Reading data from File
 Write function AddNewRecord that receive array of 10 developers and ask user to
enter complete details of developer. Call this function in main if users choose 1. [3]
 Write function UpdateRecord that receive Developer Id and an array of 10 developer.
It first search Developer Id in array and if it found the desired record then ask users to
enter the detail of developer name and exp year and CurrentProject Details he/she
wants to update. Set the new updated values in array and display the updated values. .
Call this function in main if users choose 2. [5]
 Write Function SearchRecord that asks users to enter detail of project_Name and
display details of developer and its projects. . Call this function in main if users
choose 3. [5]
 Write function Write to file that write details of developers in a file. [5]
 Write function ReadFromFile that read detail of developers from file and display it.
[5]

End of Assessment

Page 2 of 2

You might also like