Sei sulla pagina 1di 13
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

SECOND SEMESTER 2015-2016 Course Handout Part II

In addition to part-I (General Handout for all courses appended to the time table) this portion gives further specific details regarding the course.

LEGENDS USED: The course is offered in all three Indian campuses of BITS, Pilani. Most of this handout is similar for all campuses. However, campus specific details are given using the following color codes:

BITS Pilani, Pilani Campus

BITS Pilani, K K Birla Goa campus

BITS Pilani, Hyderabad campus

Course No. : CS F111 Course Title: Computer Programming

BITS Pilani, Pilani Campus

Instructors:

Name

EMail@pilani.bits-pilani.ac.in

Chamber Consultation Hours

Vishal Gupta

vishalgupta

 

Virendra Shekhawat

vsshekhawat

 

K Hari Babu

khari

 

Sunderesan Raman

sundaresan.raman

 

_

K Hari Babu khari   Sunderesan Raman sundaresan.raman   _ Please Do Not Print Unless Necessary

Please Do Not Print Unless Necessary

K Hari Babu khari   Sunderesan Raman sundaresan.raman   _ Please Do Not Print Unless Necessary
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division BITS Pilani, K K

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

BITS Pilani, K K Birla Goa Campus Instructor-in-Charge: A. BASKAR (Email: ) abaskar@goa.bits-pilani.ac.in

 

Instructors:

Name

EMail@goa.bits-pilani.ac.in

Chamber Consultation Hour

Bharat M. Deshpande

Bmd

 

Geeta Patil

geetapatil

 

Rizwan Parveen

rizwanp

 

Tirtharaj Dash

tirtharaj

 

Soumyadip Bandyopadhyay

soumyadipb

 

MAYUR JARTARKAR

p2015016

 

BITS Pilani, Hyderabad Campus Instructor-in-Charge: ARUNA MALAPATI (email: arunam@hyderabad.bits-pilani.ac.in)

Instructors:

Name

EMail@

Chamber Consultation Hour

Aruna Malapati

arunam@

 

Anand M Narsimha Murthy

 

Sanjeev Kumar Singh

 

Tathagat Ray

Rayt

 

Mrs. Prafulla K

Prafulla

 

1. Objective:

The primary goals of the course are to introduce:

Basic representation of data and how to process data using the representation inside a computer.

Techniques for specifying data, operations on data, and problem solving using a programming language.

Systematic techniques and approaches for constructing programs.

_

language.  Systematic techniques and approaches for constructing programs. _ Please Do Not Print Unless Necessary

Please Do Not Print Unless Necessary

language.  Systematic techniques and approaches for constructing programs. _ Please Do Not Print Unless Necessary
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

2. Scope:

The course covers the following topics: Basic Model of a Computer; Problem Solving Basic Computing Steps and Flow Charting (Assignment, Sequencing, Conditionals, Iteration). Programming Constructs Expressions, Statements, Conditionals, Iterators/Loops, Functions/Procedures; Data Types Primitive Types, Tuples, Choices (Unions or Enumerations), Lists/Arrays, Pointers and Dynamically Allocated Data. Input output and Files. While the topics are taught using a specific language, the intent of the course is to teach a programming methodology, and not a programming language. There is also a laboratory component that involves development and testing of iterative and procedural programs using bounded and unbounded iterations, function composition, random access lists, sequential access lists, dynamically allocated lists, and file access.

3. Text and Reference:

3 (a) Text Book:

TB1.

Education 2007.

J.R. Hanly and E.B. Koffman, Problem Solving and Program Design in C. 5th Edition. Pearson

3 (b) Reference Books:

RB1. Yale Patt, Sanjay Patel. Introduction to Computing Systems: From bits & gates to C & beyond, Second edition, McGraw Hill. RB2. Behrouz A Forouzan & Richard F Gilberg . Computer science A structured programming

approach using C. Cengage Learning 3rd Edition

RB3. Brian W. Kernighan, Dennis Ritchie. The C Programming Language. Prentice Hall. 2nd Edition.

4. Teaching Pedagogy

To improve upon the teaching pedagogy, the course will be offered using flipped classroom. It is a form of blended learning in which students will learn new content online by watching video lectures, and what used

to be homework (assigned problems) will now be done in class with instructor offering more personalized

guidance and interaction with students, instead of lecturing. The recorded content will be available on Edx portal. Edx will serve as a platform for making online content available to the students. Other than recorded content, for each student, each (logical) week will have following interactive sessions:

1. Two Lecture classes/sessions (50 mins each): Each Lecture will focus on further strengthening the concepts covered in recorded content. The video lectures for each Lecture class will be uploaded

_

in recorded content. The video lectures for each Lecture class will be uploaded _ Please Do

Please Do Not Print Unless Necessary

in recorded content. The video lectures for each Lecture class will be uploaded _ Please Do
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division ahead of time; Students

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

ahead of time; Students should listen and understand the

recorded lectures before coming to

classes and solve problems under the supervision of instructor.

2. Lab session (2 hours): For

Hyderabad

campus, there will be one lab session of 2 hours. For

campus, there will be 2 lab sessions of 1 hour each. Here, under the supervision of lab

Pilani
Pilani

and

Goa
Goa

instructors, students will solve problems on computers.

5. Course Plan 5(a): Modules

Module

Theme

Learning Objectives

I

Basic data, data types, and data representation

To understand how to define, represent, and process basic data.

II

Analyzing, designing, and managing a process or program for any given problem.

To diagrammatically understand and visualize an algorithm using boxes of various kinds. This representation gives a step by step insight to a solution of a given problem.

III

Basic Problem Solving Structured Programming

To understand constructs of structured programming including conditionals and iterations

IV

Advanced Problem Solving Program Structuring and Structured Data

To understand how to structure complex data and how to systematically structure large programs

V

User Defined Data and Dynamic Data

To understand how users can define the structure and operations of new forms of data using known forms

VI

Advanced Topics File I/O and Recursion

To understand recursive programming and to understand how to access files and contents of files

_

recursive programming and to understand how to access files and contents of files _ Please Do

Please Do Not Print Unless Necessary

recursive programming and to understand how to access files and contents of files _ Please Do
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division 5(b) Recorded lecture schedule

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

5(b) Recorded lecture schedule [Legends: RL- Recorded Lecture; LS - Lecture Session; TB - Text Book; RB - Reference Book (as mentioned in 3(b) above)]

Week

Module

Topic

Recorded

   

Number

Number

Lecture

Reference

Lecture

Number

Number

   

Introduction to the subject; teaching pedagogy

   

Self

Intro_lec

Learning

I (a)

Basics of Computing Data and Computation. Model of a computer

 

RB1: 1.1

Self

RL 1.0

to 1.7

Learning

I (b)

Binary number system; Data representation: Unsigned Integers

 

RB1: 2.1,

 

RL 1.1

2.2.1

I (d)

Data Representation: Signed Integers; Binary representation in (a) Sign magnitude, (b) one's complement, and (c) two's complement.

 

RB1:

LS1

1

RL 1.2

2.2.1, 2.3

I (e)

Advantages, disadvantages, sign extension, and range of signed integers in all three respective representations.

I (f)

Overflow in two's complement form.

RL 1.3

RB1: 2.5.3

I (g)

Floating point number representation

RL 1.4.1

RB1: 2.7.2

 

I (h)

Character, string, and other data representation.

RL 1.4.2

RB1: 2.7.3

I (i)

Conversions among decimal, binary, hexadecimal, and octal number systems (for signed, unsigned, and floating point numbers)

 

RB1: 2.4,

LS2

RL 1.5

2.7.4

I (j)

Arithmetical and logical operations on binary numbers

 

RB1: 2.5,

RL 1.6

2.6

_

and logical operations on binary numbers   RB1: 2.5, RL 1.6 2.6 _ Please Do Not

Please Do Not Print Unless Necessary

and logical operations on binary numbers   RB1: 2.5, RL 1.6 2.6 _ Please Do Not
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division   II (a) Flow

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

 

II

(a)

Flow Charts: Graphical Symbols, Examples

 

Recorded

 

RL 2.1

Lecture

LS1

II

(b)

Flow Charts: Sequential and Conditional constructs

 

Recorded

RL 2.2

Lecture

II

(c)

Flow Charts: Loops; Searching and Sorting

 

Recorded

 

RL 2.3

Lecture

LS2

III

(a)

Memory and Variables Locations, Addresses, Definitions and Declarations; Program structure

 

TB1: 2.1,

 
 

RL 3.1

2.2, 2.3,

2

2.4

LS1

III

(b)

Data types

RL 3.2.1

TB1: 2.5

III

(c)

Operators, and expressions

RL 3.2.2

TB1: 7.3

III

(d)

Expression evaluation: Operator Precedence and Associativity

RL 3.3

TB1: 2.5

 

III

(e)

Expression evaluation with different data types: type conversion (implicit and explicit)

RL 3.4

TB1: 2.5

LS2

 

III

()

Flow Charts: Graphical Symbols, Examples

 

Recorded

 
 

RL 2.1

Lecture

III

()

Flow Charts: Sequential and Conditional constructs

 

Recorded

 

RL 2.2

Lecture

III

(f)

Relational, Equality, and Logical

 

TB1: 4.1,

LS1

3

 

operators

RL 4.1

4.2

III

(g)

Sequential and Conditional execution; Control Statements (different forms of conditional statements).

RL 4.2

TB1: 4.3

III

(h)

Conditional statements: different forms of nested conditional constructs.

RL 4.3

TB1: 4.7

LS2

_

different forms of nested conditional constructs. RL 4.3 TB1: 4.7 LS2 _ Please Do Not Print

Please Do Not Print Unless Necessary

different forms of nested conditional constructs. RL 4.3 TB1: 4.7 LS2 _ Please Do Not Print
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division   III (i) Multi

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

 

III

(i)

Multi way branching: selection control mechanism using switch statement

RL 4.4

TB1: 4.8

 
 

III

()

Flow Charts: Loops; Searching and Sorting

 

Recorded

 
 

RL 2.3

Lecture

III

(j)

Problem solving using Iterative Constructs: While statement

 

TB1: 5.1,

 

RL 5.1

5.2

LS1

III

(k)

Problem solving using Iterative Constructs: For statement

 

TB1: 5.4,

4

 

RL 5.2

5.5

III

(l)

Problem solving using Iterative Constructs: Do-while statement

RL 5.3

TB1: 5.8

LS2

III

(m)

Problem solving using Nested iterative constructs

 

TB1: 5.6,

 

RL 5.4

5.7

5

 

Problem Solving on LOOPS / NESTED LOOPS

 
 

IV

(a)

Structure data: One dimensional random access lists: declaring, initializing, and accessing list elements

 

TB1: 8.1,

 
 

RL 6.1

8.2, 8.3

LS1

6

IV

(b)

Structure data: Multi-dimensional random access lists: declaring, initializing, and accessing array elements

RL 6.2

TB1: 8.7

IV

(c)

Searching: Linear Search

RL 6.3.1

TB1: 8.6

 
 

Searching: Binary search

RL 6.3.2

LS2

IV

(d)

Sorting: selection sort

RL 6.4.1

TB1: 8.6

 

Sorting: Insertion sort

RL 6.4.2

_

sort RL 6.4.1 TB1: 8.6   Sorting: Insertion sort RL 6.4.2 _ Please Do Not Print

Please Do Not Print Unless Necessary

sort RL 6.4.1 TB1: 8.6   Sorting: Insertion sort RL 6.4.2 _ Please Do Not Print
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division   IV (e) Modularity

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

 

IV

(e)

Modularity and reuse: Functions

 

TB1: 3.1,

 
 

RL7.1

3.4, 3.5

IV

(f)

Functions: Declaration, Definition, and reuse.

 

TB1: 6.1,

 

RL 7.2

6.2, 6.3,

 

6.4

LS1

7

IV

(g)

Functions: Scope of data

 

Recorded

 

RL 7.3

Lectures

IV

(h)

Functions: Problem Solving

 

Recorded

 

RL 7.4

Lectures

IV

(i)

Introduction to pointers

 

Recorded

 
 

RL 7.5

Lectures

 

IV

Argument passing to functions: by value and by reference

RL 7.6

TB1

LS2

 

IV

Arithmetic using pointers

RL 7.7

TB1

 

IV

Random access lists and pointers

RL 7.8

TB1

 

IV

(j)

Random access lists - passing arrays to functions: syntax and semantics

RL 8.1

TB1: 6.1

LS1

8

IV

Random access lists - passing arrays to functions: Problem solving

 

Recorded

 

RL 8.2

Lectures

LS1

   

Multidimensional arrays and functions:

 

TB1: 9.1,

 

9

Syntax and Semantics

RL 9.1

9.2, 9.3,

LS1

9.4

_

9.1,   9 Syntax and Semantics RL 9.1 9.2, 9.3, LS1 9.4 _ Please Do Not

Please Do Not Print Unless Necessary

9.1,   9 Syntax and Semantics RL 9.1 9.2, 9.3, LS1 9.4 _ Please Do Not
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division   IV (n) Character

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

 

IV (n)

Character Arrays

 

TB1: 9.5,

 

RL 9.2

9.6, 9.7

V(a)

Standard Library string functions: design and implementation

 

TB1: 11.1,

 

RL 9.3

11.2, 11.3

LS2

 

V

Multi-dimensional arrays AND strings

RL 9.4

TB1

 

V

(a)

Memory Layout Implicit vs. Explicit Allocation; Static vs. Dynamic Allocation; Motivation for Dynamic Allocation

RL 10.1,

   
 

RL 10.2,

TB1: 14.1,

14.2

10

 

RL 10.3

LS1

V

(b)

User defined types: typedef

RL 10.4

TB1: 14.3

V

Tuples/structures: Need, syntax, and semantics

RL 10.5

TB1: 14.4

 
 

V

Pointer to structure

RL 10.6

TB1

LS2

 

V

Random access lists and structures

RL 10.7

TB1

 

V

Tuples: Union - its need, syntax, and semantics

RL 10.8

TB1

11

V

(c)

Enumerated data types

RL 11.1

TB1: 14.4

 

V

(d)

Self referential structures

RL 11.2

TB1: 14.4

LS1

 

V

Random access list vs Sequential access list

RL 11.3

 
 

V

Linked List: creating a node and empty list

RL 11.4

 

LS2

 

V

Linked list: Inserting a node

RL 11.5

 

12

V

Linked List: Searching a sequential

RL 12.1

 

LS1, LS2

_

12 V Linked List: Searching a sequential RL 12.1   LS1, LS2 _ Please Do Not

Please Do Not Print Unless Necessary

12 V Linked List: Searching a sequential RL 12.1   LS1, LS2 _ Please Do Not
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division     access list

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

   

access list

       

V

Linked List: Deleting a node from a sequential access list

 

RL 12.1

 

V

Linked List: Example

 

RL 12.1

 
 

VI

(a)

Files and File I/O: External Storage, Files and File Systems; File Operations and I/O Operations;

RL 13.1

TB1: 12.1,

 

13

 

RL 13.2

12.2

LS1

VI

(b)

Divide and Conquer Design using Recursion ; Recursive procedures; Recursion vs. Iteration

 

RL 13.3

TB1: 10.1,

 
 

10.2, 10.3,

LS2

RL 13.4

10.4

6. Evaluation Scheme: [Legends: OB - Open Book, CB - Closed Book]

 
 

BITS Pilani, Pilani Campus

   

S.

 

Component

CB/OB

 

Time

Weight

 

Date

No.

     

1

Mid Semester Test

OB

90 Mins

25%

As per Instruction Division

2.

*Online Quizzes

 

OB

--

5%

*(Mostly) Every Week

3.

# Evaluated Labs

 

OB

--

5%

# During Lab Sessions

4.

Online Test 1

 

OB

2

Hours

17

%

TBA

5.

Online Test 2

 

OB

2

Hours

18

%

TBA

6.

Comprehensive Exam

OB

120 Mins

30

%

As per Instruction Division

*Our (logical) week will be from Wednesday to Tuesday. The recorded lectures for the n th week will be uploaded on each Saturday in (n-1) th week. On each Tuesday, a Quiz will

_

be uploaded on each Saturday in (n-1) t h week. On each Tuesday, a Quiz will

Please Do Not Print Unless Necessary

be uploaded on each Saturday in (n-1) t h week. On each Tuesday, a Quiz will
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division appear on Edx at

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

appear on Edx at 9 AM in the morning and Students have to attempt this
appear on Edx at 9 AM in the morning and Students have to attempt this Quiz by 9 PM
on the same day. Each such Quiz will be weighted for 0.5% marks and will be based on
the recorded content for the next week (i.e. n th week).
 # You are required to attend the scheduled lab sessions as per your Time Table. For each
Lab session, corresponding Lab Instructor will give your marks out of 0.5% (or 1.5
marks).
MAKE UP POLICY
 Out of N number of online quizzes, best (N-1) will be considered for final grading.
Similarly, out of M number of Lab sessions, best (M-1) will be considered in final
grading. No additional Make-up will be granted for online Quizzes and Evaluated Labs
under any condition.
 In case of Online Tests, only one make up can be granted to students who could not
take either of the two tests. Please note that there will not be individual make up for
Online test 1 and Online Test 2. Rather, there will only be one make-up for either of the
two. Of course, student has to take prior permission for it. For example, if student S1
took permission and could not appear in Online test 1 and
 Prior Permission of the Instructor-in-Charge is required to get make-up for the mid-term
test. Only on producing documentary proof of possible absence, which proves that
student would be physically unable to appear for the test/exam, the decision of
granting the make-up will be taken.
 Prior Permission of Dean, Instruction Division is required to get make-up for the
comprehensive exam.
 Instructor / Dean’s decision in the matter of granting Make-up would be final.
BITS Pilani, K K Birla Goa Campus S. Component CB/OB Time Weight Date No.
BITS Pilani, K K Birla Goa Campus
S.
Component
CB/OB
Time
Weight
Date
No.

_

BITS Pilani, K K Birla Goa Campus S. Component CB/OB Time Weight Date No. _ Please

Please Do Not Print Unless Necessary

BITS Pilani, K K Birla Goa Campus S. Component CB/OB Time Weight Date No. _ Please
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division   BITS Pilani, Hyderabad

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

AND SCIENCE, Pilani Pilani Campus Instruction Division   BITS Pilani, Hyderabad Campus   S.
 

BITS Pilani, Hyderabad Campus

 

S.

Component

CB/OB

 

Time

Weight

Date

No.

 

1

Mid Semester Test

OB

90

Mins

25%

As per Instruction Division

2.

*Online Quizzes

OB

--

5%

*(Mostly) Every Alternate Week dates will be announced via notices

3.

Lab Test1

OB

60

mins

10%

 

4.

Lab Test2

OB

60

mins

15%

 

5.

Lab Attendance

OB

 

5%

 

5.

# Evaluated Labs

OB

20

- 30 mins

10%

# During Lab Sessions every alternate week dates will be announced via notices

4.

Comprehensive Exam

OB

120 mins

30%

As per Instruction Division

*Our (logical) week will be from Monday to Saturday. The recorded lectures for the n th week will be uploaded in (n-1) th week. There will be 6 Quizzes for 1% each each. Best 5 will be selected. Quizzes will be conducted on CMS and dates will be announced as we go along. The syllabus for each quiz will be whatever has been covered till the last class before the quiz.

# There will be 6 evaluated announced Lab sessions for 2% weight each. Best 5 will be

_

There will be 6 evaluated announced Lab sessions for 2% weight each. Best 5 will be

Please Do Not Print Unless Necessary

There will be 6 evaluated announced Lab sessions for 2% weight each. Best 5 will be
BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division selected. The evaluated labs

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

selected. The evaluated labs will be autograded hence there will be no partial marking. Copying codes during labs/tests/online quiz will be reported to ID as a malpractice. MAKE UP POLICY

Out of N number of online quizzes, best (N-1) will be considered for final grading. Similarly, out of 6 number of Evaluated Lab components, best 5 will be considered for final grading. No additional Make-up will be granted for online Quizzes and Evaluated Labs under any condition.

Prior Permission of the Instructor-in-Charge is required to get make-up for the mid-term test. Only on producing documentary proof of possible absence, which proves that student would be physically unable to appear for the test/exam, the decision of granting the make-up will be taken.

Prior Permission of Dean, Instruction Division is required to get make-up for the comprehensive exam.

Instructor / Dean’s decision in the matter of granting Make-up would be final.

7. Consultation Hours: See course website

8. Notices: All notices concerning this course will be displayed on Edx webpage. Optionally, if there is a

need, email would be used on short notice only BITS Pilani mail would be used.

VISHAL GUPTA, A BASKAR, ARUNA MALAPATI Instructor In- Charge CS F111(Computer Programming)

_

A BASKAR, ARUNA MALAPATI Instructor – In- Charge CS F111(Computer Programming) _ Please Do Not Print

Please Do Not Print Unless Necessary

A BASKAR, ARUNA MALAPATI Instructor – In- Charge CS F111(Computer Programming) _ Please Do Not Print