Module Guide COMP 211 - Updated - 2017 - 2018
Module Guide COMP 211 - Updated - 2017 - 2018
Page 2 of 13
COMPUTER SCIENCE 211
Programming in C is a core module for all the undergraduate degree programmes. It serves as an
entry level programming module, and aims to introduce the skills required to write simple
structured programs in a high-level language and assess these skills in practical situations.
The core principles considered key in this module are those which underpin a practical ability to
write code: data and data structures, structured code, subroutines, parameters, loops, input/output
and files. The emphasis however, is on the creation of simple programs based on common patterns
found in software – data items, collections of items, iteration over collections and persistence.
Students learn about fundamental procedural programming concepts such as data types, operators,
expressions, flow of control and program structure. While students are encouraged to explore
additional language features themselves, instruction in the module relies on a minimalist subset of
the C language that is adequate to complete significant programming tasks
MODULE OUTCOMES
A student who successfully completes the course will have the ability to:
Page 3 of 13
MODULE COORDINATOR
Your module coordinator will be the main contact person for the module. The coordinator will be
available to assist you in anything concerning the module or refer you to an appropriate staff
member who will assist you.
If at any point during the course of the module you need help, you are to contact the module
coordinator preferably by email. The Coordinator shall assist you or direct you to the appropriate
staff member.
Email will be used most for communication. It is the responsibility of all students to make sure their
email is functional and they check it regularly. All students should make sure they have access to
blackboard.
WORK SCHEDULE
Study Week # Date Week Theme/Topic Teaching/Assessment
Beginning Method
1 20th November House Keeping Theory/Practical
Introduction to C
Programming
5 8th January
7 22nd January
9 12th Feburary
Page 4 of 13
10 19th Feburary C String Functions & Theory/practical
Introduction to
11 26th Feburary Structures
12 5th March Introduction to Theory/Practical
Unions
Introduction to C Programming
Input-Process-Output
Programming language
Compiler
Algorithm
Flowchart
Pseudo code
Variable and constant
Data types
Operators
Simple C program : printing a line of Text, adding Two integers
C Program Control
Repetition essentials
counter controlled repetition
The loop constructs: while repetition statement
for repetition statement
do … while repetition
break and continue statements
Logical operators.
C Functions
Page 5 of 13
General
Function Declaration
Function definition and function call.
Arguments and parameters
parameter passing conventions.
Pass-by-value and pass-by-reference.
Recursion.
C Arrays
Array Basics
Declaration and initialisation of arrays.
Single dimensional arrays
Multidimensional arrays
Arrays Manipulation
C String Functions
Fundamental Concepts
Basics of structures.
Declaring a structure
Creating a structure
Operations on structures
Structures and arrays.
Unions.
PRACTICAL PROGRAMS
S.No Programs
1. Write a C program to find area and perimeter of a rectangle
[Hint: area = length * breadth, Perimeter = 2(length + breadth)]
Page 6 of 13
2. Write a C program to calculate simple interest
3. Write a C program to swap two integers
4. Write a C program to accept 5 fraction numbers (floating point numbers) and find sum and
average of the numbers.
5 Program to convert temperature from degree centigrade to Fahrenheit
S.No Programs
1. Program to find whether given no is even or odd
2. Program to find greatest in 3 numbers
3. Program to find that entered year is leap year or not
4. Write a C program to accept marks scored in a subject and print the result as below
If the marks scored is less than 35 print result as fail, if the marks scored is 35 and above
and less than 50 print the result as III class, if the marks is 50 and above and less than 60
print result as II class, if the marks is 60 and above and less than 85 print result as I class
and if the marks is 85 and above and less than 100 print the result as distinction. [Use if-
else statement]
5 Write a C program to do basic arithmetic operations on given two integers by accepting
the operator from the user. Use switch case statement to do this program.
[Hint: the given operator is +, then program should give sum of given two integers, if the
operator is – , then calculate difference, if operator is * then calculate product and if
operator is /, then calculate quotient
6 Program to use switch statement. Display Monday to Sunday
S.No Programs
1. Write a C program to generate multiplication table for a given number.
2. Write a C program to find factorial of a number
3. Write a C program to find the sum of individual digits of a positive integer.
Page 7 of 13
[Hint: Given positive integer is 4557
[Sum of individual digits of a positive integer = 4+5+5+7=21]
4. Write a C program to generate first n natural numbers using for loop
5. Write a C program to generate first n Fibonacci numbers using while or for loop.
(Hint: Fibonacci series: 1 1 2 3 5 8 13 21 ……… n)
6. Write a C program to find whether the given no is palindrome or not by using while loop
S.No Programs
1. Program to find factorial of a number using recursion
2. Program to show table of a number using functions.
3. Program to swap two numbers using functions
4. Program to show table of a number using functions.
5. Program to find square of a number using functions.
S.No Programs
1. Write a C program to accept and print 1_D array.
2. Write a C program to accept and print 2_D array
3. Program to find sum of two matrices
4. Program to find subtraction of two matrices
5. Program to find multiplication of two matrices
S.No Programs
1. Write a c program to copy string using library function strcpy
2. Write a C program to concatenate strings
3. Write a C palindrome program to find whether the given string is palindrome or not
4. C Program to Store Information(name, roll and marks) of a Student Using Structure
5. C Program to Store Information of 10 Students Using Structure
6. C Program to Add Two Distances (in inch-feet) System Using Structure
Page 8 of 13
COURSE MEETING TMES:
Lectures: 2 per week (1 hour each)
LEARNING MATERIAL
PRESCRIBED TEXTBOOK:
1. Programming in ANSI C, by E. Balaguru Swamy. Tata Mc Graw Hill, ISBN No: 0-07-064822-0
REFERENCE TEXTBOOKS:
Title Author Publisher ISBN No
Page 9 of 13
MODULE ASSESSMENT
CRITERIA
Continuous Assessment will contribute 35% of the total score, with the other 65% from the Final
examination, to be written at the end of the semester
SUBMITTING ASSESSMENTS
You may also be required to sign a declaration, stating that the assignment you have submitted is
truly your own work and not copied, plagiarized either from other you, textbook, encyclopedias,
journals or the internet. If it is discovered that you have breeched this declaration, a mark of zero
shall be given.
LATE WORK
Late submission of work will be penalised by a reduction of 10% off the awarded mark for every
working day that the assignment is handed in late. Thus if an assignment is 3 days late the awarded
mark will be reduced by 30%. After three working days the assignment will not be accepted and a
zero will be awarded. All lecturers and instructors will automatically enforce this procedure.
If you believe you have a valid reason for late submission you must provide documentary evidence
to the module coordinator before you miss a test or assignment
Page 10 of 13
i) Attendance at 95% of lectures, tutorials and practicals. All practicals and tutorials missed
without valid reasons will count towards the 5% that a student has missed.
ii) Continuous assessment of at least 40%. The CA mark is calculated from marks allocated
for performance during the course, assessed as listed above under “Continuous
assessment”. These will be published at the end of the module before the final
examination.
A list of those students refused DP certification shall be published on or before the last day of
teaching of the semester.
LEAVE OF ABSENCE
An attendance register will be taken for each class and to obtain your DP you will need to attend
95% of your classes.
It is, therefore, imperative to notify the College Manager if you know you will be absent, using the
appropriate form, at least one week in advance. The College reserves the right not to grant Leave of
Absence in advance.
If you miss classes it is important that you notify the College Manager by filling in the appropriate
form and submit it with documentary evidence of why you missed the classes e.g. a doctors note,
note from a clinic, or a letter from a close family member in the case of funerals.
If you do not adhere to these procedures you may be refused your DP or if you miss a test or
laboratory or assignment you will receive a mark of zero.
There will not be an opportunity for student to do practicals outside the scheduled practical times. If
you had a valid reason and wish to do a practical on a day other than that which you have been
allocated, you will need permission from the module coordinator to do so. Please note that it is your
responsibility to inform the module coordinator well in time in order to arrange this.
BEHAVIOUR IN CLASS
It is expected that students will behave in a manner which does not impede the ability of other
students to carry out their work in class. This includes: eating or drinking in class; any kind of noisy or
disruptive behavior this includes talking in lectures; using cell phones in any class is forbidden, this
includes receiving calls or sms or replying to calls or sending any kind of message; and the use of
iPODs or any other listening device. No audio or visual recording of any kind is allowed in any class. If
any behavior is deemed to be disruptive, the lecturer or instructor may ask you to leave the class
and any cell phone or other device confiscated. Any such behaviour will be reported and may be
acted upon through the Student Code of Conduct Regulations.
Page 11 of 13
be posted after lectures in the black board, and you are welcome to print them yourselves. Some
students may seek to take another course that overlaps with the lecture time and either come late
to lecture or leave early. This should be avoided, as it disrupts the lectures and distracts the rest of
the class. Please avoid interrupting the class by arriving late or leaving early.
The weekly laboratory sessions are mandatory to attend and it is expected that you will complete
the in-lab portions during the lab hours. Lab assistants will be in lab at the time to assist you and
verify that you have completed the in-lab exercises. Lab assistants are expected to encourage
students to use Linux computing environment present on the machines in the lab. Using a single
standardized development environment will make debugging easier and ensure consistent results
across machines.
ACADEMIC MISCONDUCT
A student shall be guilty of Academic Misconduct if he or she breaches academic rules or
regulations, including false or fraudulent representation, cheating, plagiarism, intimidation, bribery
or attempted bribery, disruption of teaching, theft, copyright misuse and intellectual property theft;
possessing, using, or exchanging improperly acquired written or verbal information in the
preparation of laboratory work, a report, essay, examination, or other academic assignment;
unauthorised interaction with another student or students in the submission of academic
requirements, false claims for work submitted by a student, alteration of any academic grade or
rating so as to obtain unearned academic credit, forgery, alteration, or misuse of any University or
College document relating to the academic status of a student.
PLAGIARISM
Plagiarism Is a Serious Offence; the copying of other people’s work without full acknowledgement is
plagiarism and is regarded as a very serious offence in all contexts. The University regards this as a
particularly serious offence, which will be recorded on the academic record of any student found
guilty of plagiarism. Such a student will either be asked to sign an Admission of Guilt form or have
the matter referred to the Student Code Committee.
Following the signing of an Admission of Guilt form, the student’s name, student number and
offence are published on the University Notice System and any mark for the relevant assignment is
cancelled.
In serious cases, following a hearing in the Student Code Committee, the student may be excluded
from the University.
Page 12 of 13
There is an increasing tendency for students to find suitable internet sites and simply copy large
parts of these sites as their own work. This is easily detected. While students are encouraged to use
the internet, note that you are obliged to acknowledge your sources.
Page 13 of 13