CNG140 Spring 2024 2025 Syllabus
CNG140 Spring 2024 2025 Syllabus
Credits/ECTS:
(3-2) 4 / 4
Catalog Description:
Advanced programming with C: storage and control structures, recursion and programming with dynamic data structures.
Homeworks are required to run on Unix environment.
Instructors:
Dr. Yeliz Yesilada Office: S-223 Phone: x-2994 email: [email protected] [Section 1]
Dr. Idil Candan Office: S-135 Phone: x-2963 email: [email protected] [Section 2, 3 & 4]
Dr. Muhammad Toaha Raza Khan Office: S-137 Phone: x-2965 email: [email protected] [Section 5]
Lecture Hours:
Section 1: Monday, 08:40-10:30 [TZ-20] && Wednesday, 13:40-14:30 [I-103]
Section 2: Monday, 08:40-10:30 [TZ-07] && Wednesday, 13:40-14:30 [I-106]
Section 3: Tuesday, 15:40-17:30 [TZ-20] && Wednesday, 12:40-13:30 [I-103]
Section 4: Wednesday, 08:40-10:30 [TZ-07] && Thursday, 12:40-13:30 [I-103]
Section 5: Monday, 08:40-10:30 [T-105] && Wednesday, 13:40-14:30 [I-104]
Laboratory Hours:
Section 1: Friday, 10:40-12:30 [I-103]
Section 2: Friday, 10:40-12:30 [RZ-03]
Section 3: Friday, 13:40-15:30 [I-103]
Section 4: Friday, 13:40-15:30 [I-104]
Section 5: Friday, 13:40-15:30 [I-106]
Teaching Assistant:
Ali Shafique, email: [email protected]
Burak Sarpkaya, email: [email protected]
Sameh Algharabli, email: [email protected]
Suleiman T. Suleiman: email: [email protected]
Zeycan Demirağ: email: [email protected]
Textbook:
• Gary J. Bronson, A First book of ANSI C, Fourth Edition, 2007, ISBN: 9781418835569.
• Brian W. Kernighan and Dennis M. Ritchie, The C Programming Language, Second Edition, 1988, Pearson, ISBN:
0131103628.
Course Prerequisites:
None officially but CNG111 is a must as unofficial prerequisite. Students are strongly not recommended to take CNG140
if they did not pass CNG111.
Learning Outcomes:
At the end of this course, students will be able to:
1. Understand basic data types such as int, float and arrays and understand how different types of data can be
represented and used in computational expressions.
2. Differentiate computational evaluation of expressions from mathematical evaluation due to concepts such as
overflow, side-effect, and truncation.
3. Understand and apply structured programming concepts by elaborating on sequential, selective, repetitive
structures, such as statements, if/switch/case statements, and for/while statements.
4. Understand the run-time behavior of a program in terms of memory management and function execution and
apply their knowledge on run-time behavior of a program for effectively predicting the outcome of a program.
5. Check the correctness of a given program in terms of compile-time and run-time behavior.
1
6. Remember and use widely used C standard library functions, such as input/output functions and string functions,
in a program.
7. Critique on a code’s readability in terms of variable naming, modularity, indentation.
8. Interpret a computational problem specification and algorithmic solution and implement a solution in C to solve
that problem
9. Construct new composite data types such as 3D Point, Vector using struct and union.
10. Modify an existing solution to a problem to accommodate for extension and/or change of problem specifications.
11. Design a modular solution to a problem by decomposing it into smaller sub-problems.
12. Understand and apply pointer operations and dynamic memory management functions effectively.
13. Understand file operations using standard input/output function for reading and writing files.
Grading:
Practical Assignments: 10%
Quizzes: 20%
Midterm Exam: 35%
Final Exam: 35%
2
12 05/05 Data files: Declaring, opening and closing file streams, reading and
writing text, binary files.
13 12/05 Structures: Basics of structures, structures and functions, arrays of Practical Assignment – 2
structures. (Pointers, Functions,
Structures, Dynamic
Memory Allocation/Files)
14 19/05 Files, Arrays, Pointers, Structures: More on structures, variable Quiz-4 (Structures and
length structures, files, pointers to structures, arrays and Dynamic Memory
structures and bitwise operations. Allocation)
15 26/05 Revision
Final Exam Week (11 June – 23 June, 2025) Final
Development Environment:
You can use a simple text editor and a C compiler, for example GCC C or you can use an Integrated Development
Environment (IDE). You are strongly recommended to use CLion:
• Further details about CLion is available here: https://www.jetbrains.com/clion/
• For Free Educational Licenses, you need to fill in this form: https://www.jetbrains.com/shop/eform/students
3
Makeup Exam Policy:
There will be no make-up exams unless the student has a valid medical leave approved by the METU NCC Health Center.
Students who provide a valid medical leave approved by the METU NCC Health Center will be eligible for a makeup
examination, subject to the following regulations:
a. There will be a single makeup exam.
b. The makeup examination will be conducted after the final exams at the end of the semester.
c. The makeup examination will be comprehensive and can cover all topics addressed throughout the semester,
regardless of the specific exam missed (e.g., quizzes, midterm, final).
d. The grade obtained in the comprehensive makeup examination will replace the grade of the missed assessment.
e. In the unlikely cases where a student missed multiple exams with valid medical documentation, the grade of the
makeup exam will replace the grades of all the missed elements.
Cheating:
Full description of cheating, please refer to https://ncc.metu.edu.tr/res/academic-code-of-ethics, but here we provide a
description for assignments/exams/quizzes in this course. The following will be considered as cheating:
Prepared by: Yeliz Yesilada, Idil Candan and Muhammad Toaha Raza Khan Date: February, 2025