151x Filetype PDF File size 1.81 MB Source: mrcet.com
PYTHON PROGRAMMING (R18A0513) LECTURE NOTES B.TECH III YEAR – I SEM (R18) (2020-2021) MALLA REDDY COLLEGE OF ENGINEERING & TECHNOLOGY (Autonomous Institution – UGC, Govt. of India) Recognized under 2(f) and 12 (B) of UGC ACT 1956 (Affiliated to JNTUH, Hyderabad, Approved by AICTE - Accredited by NBA & NAAC – ‘A’ Grade - ISO 9001:2015 Certified) Maisammaguda, Dhulapally (Post Via. Hakimpet), Secunderabad – 500100, Telangana State, India PYTHON PROGRAMMING III YEAR/I SEM MRCET SYLLABUS MALLA REDDY COLLEGE OF ENGINEERING AND TECHNOLOGY III Year B. Tech CSE - I SEM L T/P/D C 3 - / - / - 3 (R18A0513) PYTHON PROGRAMMING OBJECTIVES: • To read and write simple Python programs. • To develop Python programs with conditionals and loops. • To define Python functions and call them. • To use Python data structures –- lists, tuples, dictionaries. • To do input/output with files in Python. UNIT I INTRODUCTION DATA, EXPRESSIONS, STATEMENTS Introduction to Python and installation, variables, expressions, statements, Numeric datatypes: Int, float, Boolean, string. Basic data types: list--- list operations, list slices, list methods, list loop, mutability, aliasing, cloning lists, list parameters. Tuple --- tuple assignment, tuple as return value, tuple methods. Dictionaries: operations and methods. UNIT II CONTROL FLOW, LOOPS Conditionals: Boolean values and operators, conditional (if), alternative (if-else), chained conditional (if-elif-else); Iteration: statements break, continue. Functions--- function and its use, pass keyword, flow of execution, parameters and arguments. UNIT III ADVANCED FUNCTIONS, ARRAYS Fruitful functions: return values, parameters, local and global scope, function composition, recursion; Advanced Functions: lambda, map, filter, reduce, basic data type comprehensions. Python arrays: create an array, Access the Elements of an Array, array methods. UNIT IV FILES, EXEPTIONS File I/O, Exception Handling, introduction to basic standard libraries, Installation of pip, Demonstrate Modules: Turtle, pandas, numpy, pdb, Explore packages. UNIT V OOPS , FRAMEWORK Oops concepts: Object, Class, Method, Inheritance, Polymorphism, Data abstraction, Encapsulation, Python Frameworks: Explore django framework with an example OUTCOMES: Upon completion of the course, students will be able to • Read, write, execute by hand simple Python programs. • Structure simple Python programs for solving problems. PYTHON PROGRAMMING III YEAR/I SEM MRCET • Decompose a Python program into functions. • Represent compound data using Python lists, tuples, dictionaries. • Read and write data from/to files in Python Programs TEXT BOOKS 1.Allen B. Downey, ``Think Python: How to Think Like a Computer Scientist‘‘, 2nd edition, Updated for Python 3, Shroff/O‘Reilly Publishers, 2016. 2.R. Nageswara Rao, “Core Python Programming”, dreamtech 3. Python Programming: A Modern Approach, Vamsi Kurama, Pearson REFERENCE BOOKS: 1. Core Python Programming, W.Chun, Pearson. 2. Introduction to Python, Kenneth A. Lambert, Cengage 3. Learning Python, Mark Lutz, Orielly PYTHON PROGRAMMING III YEAR/I SEM MRCET INDEX UNIT TOPIC PAGE NO INTRODUCTION DATA, 1 EXPRESSIONS, STATEMENTS Introduction to Python and installation 1-6 Variables 6-8 Expressions 8-11 Statements 11-12 Numeric data types: Int, float, Boolean, 12-24 string. I Basic data types: 24 list--- list operations, list slices, list 24-34 methods, list loop, mutability aliasing, cloning lists, list parameters. 34-36 Tuple --- tuple assignment, tuple as return 36-44 value, tuple methods Dictionaries: operations and methods 44-48 CONTROL FLOW, LOOPS Conditionals: Boolean values and 49 operators, II conditional (if) 50-51 alternative (if-else) 51-52 chained conditional (if-elif-else) 53-54 Iteration: statements, break, continue. 55-67 Functions--- function and its use 67-68 pass keyword 68 flow of execution 69-70 parameters and arguments 70-82 ADVANCED FUNCTIONS, 83 ARRAYS Fruitful functions: return values 83-85 Parameters 85-87 local and global scope 87-90 III function composition 90-91 Recursion 91-92 Advanced Functions: lambda, map, filter, 92-96 reduce basic data type comprehensions 96-99
no reviews yet
Please Login to review.