Computer Programming (University of Rajasthan, August-November 2015)
Instructor: Sanjeev Kumar
Home | Assignments | Notes | Links | Contact
This is a Masters in Physics course at Department of Physics, University of Rajasthan, Jaipur. Course is now over and page is being preserved as is.
Several textbooks will be used during the course. The five books pictured above (click to enlarge) are among the recommended ones. A list of other C-programing language textbooks can be found on the internet.
The course contents are as follows:
- Basic concepts of programming languages: Programming domains, language evaluation criterion and language categories. Describing Syntax and Semantics, formal methods of describing syntax, recursive descent parsing, attribute grammars, dynamic semantics. Names, Variables, Binding, Type checking, Scope and lifetime.
- Data types, array types, record types, union types, set types and pointer types, arithmetic expressions, type conversions, relational and Boolean expressions, assignment statements, mixed mode assignment, statement level control structure, compound statements, selection statement, iterative statements, unconditional branching, guarded commands. Fundamentals of sub-program, design issues, parameter passing methods, overloaded subprograms, generic subprograms, separate and independent compilation, desing issues for functions, accessing nonlocal enviroment, user defined overloaded operators, implementing subprograms, blocks, implementing dynamic scooping.
- Programming in C: Character set, variables and constants, keywords, Instructions, assignment statements, arithmetic expression, comment statements, simple input and output, Boolean expressions, Relational operators, logical operators, control structures, decision control structure, loop control structure, case control structure, functions, subroutines, scope and lifetime of identifiers, parameter passing mechanism.
- Arrays and strings, structures, array of structures, Unions of structures, operations on bits, usage of enumerated data types. Bit-fields, Pointers to Function, Function returning Pointers.
In above list, I will teach topics given in 3rd and 4th bullets. Prof A.K. Nagawat will take care of first two parts. Mainly, I am following the book Deitel. (pdf) (google drive).
Book by Robert B. Sebesta can be found here. (pdf) (google drive)
Assignments
- Assignment 1: Assigned 31 August 2015, due 11 September 2015.
- Assignment 2: Assigned 28 September 2015, due 4 October 2015. (Latex File)
- Midterm: 15 October 2015 (Latex File)
- Assignment 3: 5 October 2015, due 8 November 2015. (Latex File)
Notes
These are handwritten notes/slides that I prepare to help me teach the course. Although I usually use them while teaching, there are occasions when I teach something that was not written in the notes, or do not teach something that I had written in the notes. So they are not an accurate record of the course (nor are they intended to be). Also, though each set of notes is roughly matched to a given lecture, it often happens that part of the material written for a given lecture is taught in the following lecture (if I run out of time).
- Revision Lecture 0.1, 0.2: What is a language: 3 and 4 August 2015 References: Deitel 6th edition, Page 2-6; The Art of Programming Through Flowcharts & Algorithms by Anil Bikas Chaudhuri, Page 1-3
- Lecture 1: First program in c-language and errors in it.: 10 August 2015 (first file)
- Lecture 2: Arithmetic in c-language and their precedence.: 11 August 2015 (c file)
- Lecture 3,4 : Decision making and structured program development in C.: 17 August 2015 (file 1, file 2, file 3 and file 4)
- Lecture 5: The While Repetition Statement: 31 August 2015 (Please have a look at files file_1 and file_2)
- Lecture 6: Switch Multiple-Section Statement: 1 September 2015 (Please have a look at files file_1 and file_2)
- Lecture 7: Break, Continue statement in for loop: 7 September 2015 (file1 and file2)
- Lecture 8: Functions definitions and function prototypes in C: 8 September 2015 (file1, file2 and file 3)
- Lecture 9: Different datatypes and recursion: 14 September 2015 (file 1, file 2 and file 3)
- Lecture 10: Random Number Generation and Scope rules: 15 September 2015 (file1, file2, file 3 and file 4)
- Lecture 11: C-Arrays: 21 September 2015 (file 1, file 2, file 3 and file 4)
- Lecture 12: C-Arrays (few more examples): 22 September 2015 (file 1, file 2, file 3, file 4 and file 5)
- Lecture 13: C-Pointers: 28 September 2015 (file 1, file 2, file 3, file 4, file 5, file 6, file 7, file 8 and file 9)
- Lecture 14: Binary operators, Pointers to Functions: 29 September 2015 (file 1, file 2 and file 3)
- Lectrue 15: C Characters and Strings: 5 October 2015 (file 1 and file 2)
- Lecture 16: C Characters and Strings (part 2): 6 October 2015 (file 1, file 2, file 3, file 4, file 5, file 6 and file 7)
- Discussion on midterm question paper and answers.: 19 October 2015
- Lecture 17: C Formatted Input/Output: 20 October 2015 (file 1, file 2, file 3, file 4 and file 5)
- Lecture 18: C Structures, Unions and Enumerations: 16 November 2015 (file 1, file 2, file 3, file 4, file 5 and file 6)
- Lecture 19: C File Processing: 17 November 2015 (file 1, file 2, file 3, file 4, file 5, file 6, file 7 and file 8)
- On Leave: 23 November 2015
- Lecture 20: C Data Structures and C Preprocessor: 24 November 2015 (file 1, file 2, file 3, file 4, file 5 and file 6)
- Lecture 21: Other C Topics: 30 November 2015 (file 1, file 2, file 3 and file 4)
Pre-requisites: The basic pre-requisites for this course are a proper knowledge of basic logics and algorithm makings: How to solve a problem by hand and how to work logic.
Dates and timings:
- Monday and Tuesday, 10:00 AM – 11:00 AM
- Starting date: Revision of pre-requisites from August 3, new course material from August 10, 2015.
Venue: Smart room 2
Links:
- C-programming Wikipedia page
- Introduction to C Programming (Leicester University)
- Lectures on C-programming by LearningLad (Youtube)
- Handbook of Physics C-programing (Oxford University)
- Lectures by Prof A.K. Nagawat (UOR)
- Old sample questions: 1st and 2nd semester
Contact:
- Email: sanjeev@uniraj.ac.in
- Office: R201
- Mobile: +91 9462807073
Calendar: My Calendar and availability