Unit 1: Introduction to Programming. Saurabh Khatri Lecturer Department of Computer Technology VIT, Pune

Similar documents
Programming for Problem Solving 105A L T P Credit Major Minor Total Time

Computer System and programming in C

Kadi Sarva Vishwavidyalaya, Gandhinagar

DR. A.P.J. ABDUL KALAM TECHNICAL UNIVERSITY LUCKNOW. Evaluation Scheme & Syllabus. For. B.Tech. First Year (Programming for Problem Solving)

Hrs Hrs Hrs Hrs Hrs Marks Marks Marks Marks Marks

ITC213: STRUCTURED PROGRAMMING. Bhaskar Shrestha National College of Computer Studies Tribhuvan University

Fundamentals of Programming. Lecture 1: Introduction to C Programming

Computer Fundamentals

Gujarat University M. Sc. Computer Science [S. F.] Semester-1 Syllabus Gujarat Arts & Science College, Ahmedabad.

Deccan Education Society s FERGUSSON COLLEGE, PUNE (AUTONOMOUS) SYLLABUS UNDER AUTONOMY. FIRST YEAR B.Sc. COMPUTER SCIENCE SEMESTER I

LECTURE/ STUDY NOTES ON C

Proposed Syllabus for F.Y.B.Sc.( Computer Science) North Maharashtra University, Jalgaon. F.Y.B.Sc.( Computer Science) (w.e.f.

Week 1 Introduction to Computer and Algorithm (Part1) UniMAP Sem II 11/12 DKT121: Basic Computer Programming 1

Class 8 ALGORITHMS AND FLOWCHARTS. The City School

Engineering Computing M1H Together Towards A Green Environment

ENT 189: COMPUTER PROGRAMMING. H/P: Home page:

Syllabus of Diploma Engineering. Computer Engineering. Semester: II. Subject Name: Computer Programming. Subject Code: 09CE1104

UNIVERSITY OF JAMMU, JAMMU. (Semester System)

Operating System Study Material

CSCI 2132 Software Development. Lecture 2: Introduction to UNIX and Unix-like Operating Systems

Swami Ramanand Teerth Marathwada University, Nanded

SYSTEM PROGRAMMING & SYSTEM ADMINISTRATION SECTION -A

Academic Programme: B.Sc. I Year. Computer Science (Optional) Hours. Fundamentals of Computer Hours.

Lecture 1: Preliminaries

Administration Computers Software Algorithms Programming Languages

C++ Programming Language Lecture 2 Problem Analysis and Solution Representation

Introduction to C Programming

Course Title: C Programming Full Marks: Course no: CSC110 Pass Marks: Nature of course: Theory + Lab Credit hours: 3

CSC 453 Operating Systems

Outline. Program development cycle. Algorithms development and representation. Examples.

Programming 1. Lecture 1 COP 3014 Fall August 28, 2017

AE Computer Programming for Aerospace Engineers

Syllabus For F. Y. B. Sc. Semester 1 Core Paper No.: 102 Core Paper Title: Programming in C I 1. Algorithm & Flowcharting 2. Programming Languages & S

1.The First Instrument known in the history of computers was. a) Pascal s adding machine b) Napier s bones c) Abacus d) Analytical Engine

Syllabus of ENPM 691: Secure Programming in C

by Pearson Education, Inc. All Rights Reserved.

COMP1917: Computing 1 1. Introduction

ENGINEERING PROGRAMMING

COMP1917: Computing 1 1. Introduction

PROGRAMMAZIONE I A.A. 2017/2018

ALGORITHMS AND FLOWCHARTS

Chapter 14 Operating Systems

Chapter 14 Operating Systems

1. Introduction. Course Web Site. COMP1917: Computing 1. Textbook. Occupational Health and Safety (OHS)

Introduction to Basis and Practice in Programming

PSEUDOCODE AND FLOWCHARTS. Introduction to Programming

B.Sc. Computer Science (Ancillary)

Course and Unix Intro

Introduction to OS. Introduction MOS Mahmoud El-Gayyar. Mahmoud El-Gayyar / Introduction to OS 1

CHOICE BASED CREDIT SYSTEM (With effect from )

Unit 1: Introduction to C Language. Saurabh Khatri Lecturer Department of Computer Technology VIT, Pune

NORTH MAHARASHTRA UNIVERSITY, JALGAON. SYLLABUS FOR F.Y.B.Sc. COMPUTER SCIENCE (With effect from June 2012)

CS 113: Introduction to

Class 9 Saturday, Feb 14

Software Project. Lecturers: Ran Caneti, Gideon Dror Teaching assistants: Nathan Manor, Ben Riva

Instructor. Mehmet Zeki COSKUN Assistant Professor at the Geodesy & Photogrammetry, Civil Eng. (212)

DEPARTMENT OF INFORMATION TECHNOLOGY KUMAUN UNIVERSITY, NAINITAL SEMESTER-I ( ) Scheme and syllabus for B.A./B. Sc. (Information Technology)

INTRODUCTION TO ALGORITHMS

Principles of computer programming. Profesor : doc. dr Marko Tanasković Assistent : doc. dr Marko Tanasković

Introduction to Cygwin Operating Environment

Programming 1 - Honors

CS11001/CS11002 Programming and Data Structures Autumn/Spring Semesters. Introduction

G. PULLAIAH COLLEGE OF ENGINEERING AND TECHNOLOGY Pasupula, Nandikotkur Road, Kurnool

0 Introduction: Computer systems and program development

Programming Fundamentals (CS 302 ) Dr. Ihsan Ullah. Lecturer Department of Computer Science & IT University of Balochistan

Computer Fundamentals: Pradeep K. Sinha & Priti Sinha

CS 240 Fall 2015 Section 004. Alvin Chao, Professor

Syllabi & Scheme of Examination BCA-1 st Year/DCST. Website:-

CSc 10200! Introduction to Computing. Lecture 1 Edgardo Molina Fall 2013 City College of New York

OHIO ASSESSMENTS FOR EDUCATORS (OAE) FIELD 010: COMPUTER INFORMATION SCIENCE

CS 241 Data Organization. August 21, 2018

Fundamentals of Programming (C)

Contents. * All rights reserved, Tei-Wei Kuo, National Taiwan University, 2003.

AT76.09 Digital Image Processing in Remote Sensing using C Language

The C Programming Language By Brian W. Kernighan;Dennis M. Ritchie

Introduction to Java Programming

CS120 Computer Science I. Instructor: Jia Song

C++ Programming Language Lecture 1 Introduction

Chapter 1: An Overview of Computers and Programming Languages. Objectives. Objectives (cont d.) Introduction

ADDMISSION-CALL / / WEBSITE:-

Operating Systems CS3502 Spring 2018

History of C Programming Language. Why Name C was given to Language? Summary of C Programming Language History. C Programming Language Timeline:

CNG 140 C Programming. Syllabus. Course Info Fall Semester. Catalog Description

Operating System Labs. Yuanbin Wu

CS11002 Programming and Data Structures Spring Introduction

Rayat Shikshan Sanstha s Yashavantrao Chavan Institute of Science Satara Department of Computer Science. Syllabus for Bachelor of Science Part-I

Chapter 1 Introduction to Computers and C++ Programming

Introduction to Linux Overview and Some History

Unix API Books. Linux Kernel Books. Assignments and Exams. Grading for CSC 256. Operating Systems 8/31/2018. CSC 256/456 Fall

CS 241 Data Organization using C

1 The Catholic University of Eastern Africa P.o Box , Nairobi Kenya Edward Kioko 2013

Software Concepts. It is a translator that converts high level language to machine level language.

Syllabus Under Autonomy Mathematics

Spring 2018 NENG 202 Introduction to Computer Programming

Menu. Class 1: Introduction. Staff. Course Structure and Expectations. Contacting Us. Contacting You

ITT Technical Institute. ET2560T Introduction to C Programming Onsite and Online Course SYLLABUS

COURSE OUTLINE & WEEK WISE BREAKAGE

C- PROGRAMMING (3:0:0) Sub code : CS1C01/CS2C01 CIE : 50%Marks Hrs/week : 03 SEE : 50%Marks SEE Hrs : 03 Hours Max. Marks: 100 Course Outcomes:

SIR C.R.REDDY COLLEGE OF ENGINEERING, ELURU DEPARTMENT OF INFORMATION TECHNOLOGY LESSON PLAN

Programming for Engineers: Getting Started

Transcription:

Unit 1: Introduction to Programming Saurabh Khatri Lecturer Department of Computer Technology VIT, Pune

Syllabus Unit 1: Introduction to Programming Unit 2: Flow of Control and Functions Unit 3: Arrays and Strings Unit 4: Pointers and Structures Unit 5: Recursive Functions Sorting and Searching

Books to refer Let us C, Y. Kanetkar, Second Edition, BPB Publication. ISBN: 8176566217. Programming In Ansi C By E. Balagurusamy Tata McGraw-Hill Education, 2008 Programming language ANSI C, Brain W Kernighan and Dennis Ritchie, Second edition ISBN 0-13-110370-9, Fundamentals of Computer System - Pradeep Sinha. For Unit 1

Assessment Total assessment = 100 15 CT (7.5) on Unit 1+ HA (6*5 = 30 ------ 7.5) Part B 20 Mid Sem (Online test) MCQ Unit 2,3 65 End Sem (100 marks to be converted to 65) [Distribution of Marks Unit wise : 14+14+14+22+22+14]

What is a Computer?

4 Functions of a Computer Input : Any raw data given to Computer system Processing : Operations on Input according to set of instructions. Output : Interpreting processed information to User Storage : Storing the results for future use.

Block Diagram of Computer

Operating System

Operating Systems System Software that controls the entire Computer System. Provides user with an interface to work with the Machine More convenient Two way work of OS : Convenience + Resource management Main functions Process mgmt Memory mgmt File mgmt Security

DOS OS that provides management of secondary storage devices Extension to the OS DOS was first used for IBM PCs using 32-bit Intel Processors (x86). Microsoft developed the - Microsoft Disk Operating System (MSDOS), MS windows 2007, XP are coming from it. Replaced by Windows OS completely Examples include DOS/360 and FreeDOS.

UNIX OS Unix is a multitasking, multi-user computer operating system Developed in 1969 by a group of AT&T Bell Labs Contributors includes Ken Thompson, Dennis Ritchie, Brian Kernighan and team Unix written in C language.

Levels of Programming Language Machine Language Consists of combination of 0 s and 1 s that represent high and low electrical voltage. Unsuitable for programming, difficult to program. Machine dependent. Error prone. All programs are converted into machine language before they can be executed.

Levels of Programming Language Assembly Language Similar to Machine level but replacing 0s and 1s with Names and symbols Also known as Object code Uses symbolic codes to represent the machine operation code More readable Can be used to write instructions. Ex: ADD ------- 3E, etc Platform Dependent.obj extension

Levels of Programming Language High-Level Languages Programming languages that are easier to learn. Uses English like statements. Readable familiar notations Availability of program libraries Platform Independent. Hides the details of computer. Example C language (.c extension)

Execution of a Program High Level source code(.c) Middle level object code(.obj) Low level executable code(.exe)

Program Execution

Program Execution Compiler Assembler Linker Loader Interpreter (Video - )

ALGORITHMS AND FLOWCHARTS A typical programming task can be divided into two phases: Problem solving phase produce an ordered sequence of steps that describe solution of problem this sequence of steps is called an algorithm Implementation phase implement the program in some programming language

Example 1 Example 1:Write an algorithm to determine a student s final grade and indicate whether it is passing or failing. Algorithm Step 1: Start Step 2: Input M1,M2,M3,M4 Step 3: Step 4: Step 5: GRADE (M1+M2+M3+M4)/4 if (GRADE < 50) then Print FAIL else Print PASS endif Stop

Flowchart A graphical representation of the sequence of operations in an information system or program. Different symbols are used to draw each type of flowchart. A Flowchart shows logic of an algorithm emphasizes individual steps and their interconnections e.g. control flow from one action to the next

Flowchart Symbols Basic

Example START Input M1,M2,M3,M4 GRADE (M1+M2+M3+M4)/4 Step 1: Step 2: Step 3: Input M1,M2,M3,M4 GRADE (M1+M2+M3+M4)/4 if (GRADE <50) then Print FAIL else Print PASS endif N IS GRADE<50 Y PRINT PASS PRINT FAIL STOP

Example 2 Write an algorithm and draw a flowchart that will read the two sides of a rectangle and calculate its area.

Example 2 Algorithm Step 1: Step 2: Step 3: Input W,L A L x W Print A START Input W, L A L x W Print A STOP

Example 3 Write an algorithm and flowchart to print the factorial of a no. N.

Revision 15 Marks 1. 4 functions of Computer? 2. Why RAM is also called Non Volatile. 3. Which is faster secondary or primary memory? 4. Function of control unit? 5. What is OS example 6. C is a level language. 7. Machine code contains and has an extension. 8. What is the function of Linker. 9. C is a Interpreted Language? T or F. 10. Loader is part of and is used to. 11. For processing the executable file are brought to from. 12. Write an example of O/P and I/P device. 13. Interpretation process does not create any. That s why it has a drawback. 14. Assembler function is to. 15. is box