[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"detail-sidebar-cat-0-en-105":3,"doc-seo-417799-105":59,"doc-detail-417799-en":131,"doc-similar-417799":212},{"code":4,"msg":5,"data":6},0,"success",[7,13,18,23,28,33,38,43,48,51,55],{"id":8,"doc_module":4,"doc_module_name":9,"category_name":10,"show_sort_weight":11,"slug":12},1,"Document","Story & Novel",90,"story-novel",{"id":14,"doc_module":4,"doc_module_name":9,"category_name":15,"show_sort_weight":16,"slug":17},2,"Literature",80,"literature",{"id":19,"doc_module":4,"doc_module_name":9,"category_name":20,"show_sort_weight":21,"slug":22},4,"Exam",70,"exam",{"id":24,"doc_module":4,"doc_module_name":9,"category_name":25,"show_sort_weight":26,"slug":27},5,"Comic",60,"comic",{"id":29,"doc_module":4,"doc_module_name":9,"category_name":30,"show_sort_weight":31,"slug":32},6,"Technology",50,"technology",{"id":34,"doc_module":4,"doc_module_name":9,"category_name":35,"show_sort_weight":36,"slug":37},7,"Healthcare",40,"healthcare",{"id":39,"doc_module":4,"doc_module_name":9,"category_name":40,"show_sort_weight":41,"slug":42},8,"Research & Report",30,"research-report",{"id":44,"doc_module":4,"doc_module_name":9,"category_name":45,"show_sort_weight":46,"slug":47},9,"Religion & Spirituality",20,"religion-spirituality",{"id":46,"doc_module":4,"doc_module_name":9,"category_name":49,"show_sort_weight":46,"slug":50},"World Cup","world-cup",{"id":52,"doc_module":4,"doc_module_name":9,"category_name":53,"show_sort_weight":52,"slug":54},10,"Lifestyle","lifestyle",{"id":56,"doc_module":4,"doc_module_name":9,"category_name":57,"show_sort_weight":24,"slug":58},19,"General","general",{"code":4,"msg":60,"data":61},"ok",{"site_id":62,"language":63,"slug":64,"title":65,"keywords":66,"description":67,"schema_data":68,"social_meta":124,"head_meta":126,"extra_data":128,"updated_unix":130},105,"en","python-programming-r17a0554-lecture-notes-btech-iii-year-ii-sem","PYTHON PROGRAMMING - R17A0554 - Lecture Notes - B.TECH III YEAR II SEM","","Lecture notes for the course “Python Programming” (R17A0554) for B.Tech III Year II Semester (R17), Malla Reddy College of Engineering and Technology (MRCET). The syllabus covers Python fundamentals and installation, data types, expressions, statements, operator precedence, comments, modules and functions, and execution flow with parameters and arguments. It also covers control flow and loops, fruitful functions with return values, recursion, scope rules, string operations, arrays, lists/tuples/dictionaries with comprehension, and file handling with exceptions, plus modules and packages.",{"@graph":69,"@context":123},[70,84,106],{"@type":71,"itemListElement":72},"BreadcrumbList",[73,77,79,82],{"item":74,"name":75,"@type":76,"position":8},"https://docshare.wps.com","Home","ListItem",{"item":78,"name":9,"@type":76,"position":14},"https://docshare.wps.com/document/",{"item":80,"name":30,"@type":76,"position":81},"https://docshare.wps.com/document/technology/",3,{"item":83,"name":65,"@type":76,"position":19},"https://docshare.wps.com/document/python-programming-r17a0554-lecture-notes-btech-iii-year-ii-sem/417799/",{"url":83,"name":65,"@type":85,"image":86,"author":91,"headline":65,"publisher":94,"fileFormat":97,"inLanguage":63,"description":67,"dateModified":98,"datePublished":99,"encodingFormat":97,"isAccessibleForFree":100,"interactionStatistic":101},"DigitalDocument",{"url":87,"@type":88,"width":89,"height":90},"https://docshare.wps.com/thumbnails/python-programming-r17a0554-lecture-notes-btech-iii-year-ii-sem/417799.png","ImageObject",300,407,{"name":92,"@type":93},"Rowan","Person",{"url":74,"name":95,"@type":96},"DocShare","Organization","application/pdf","2026-11-30","2026-09-28",true,{"@type":102,"interactionType":103,"userInteractionCount":105},"InteractionCounter",{"@type":104},"ViewAction",15,{"@type":107,"mainEntity":108},"FAQPage",[109,115,119],{"name":110,"@type":111,"acceptedAnswer":112},"What topics are covered in Unit I of Python Programming (R17A0554)?","Question",{"text":113,"@type":114},"Unit I covers Python introduction and installation, data types (Int, float, Boolean, string, list), variables, expressions, statements, operator precedence, comments, and modules/functions with execution flow, parameters, and arguments.","Answer",{"name":116,"@type":111,"acceptedAnswer":117},"How does the course explain control flow and loops?",{"text":118,"@type":114},"Unit II focuses on conditionals (if, if-else, if-elif-else) and iteration using while and for, including break and continue statements.",{"name":120,"@type":111,"acceptedAnswer":121},"What file-related and error-handling concepts are included?",{"text":122,"@type":114},"Unit V includes reading and writing text files, command line arguments, errors and exceptions, and handling exceptions, along with modules and package exploration.","https://schema.org",{"og:url":83,"og:type":125,"og:title":65,"og:site_name":95,"og:description":67},"article",{"robots":127,"canonical":83},"index,follow",{"doc_id":129,"site_id":62},417799,1790821275,{"code":4,"msg":5,"data":132},{"doc_id":129,"user_id":133,"nickname":92,"user_avatar":134,"doc_module":4,"category_id":29,"category_name":30,"doc_title":65,"doc_description":67,"doc_content":135,"file_id":136,"file_url":137,"file_type":138,"file_size":139,"view_count":105,"is_deleted":4,"is_public":8,"is_downloadable":8,"audit_status":8,"page_count":140,"language":141,"language_code":63,"site_id":62,"html_lang":63,"table_of_contents":142,"faqs":143,"seo_title":144,"seo_description":67,"update_tm":145,"read_time":146,"preview_page_count":105,"preview_urls":147},1099514067415,"https://ap-avatar.wpscdn.com/avatar/100002539d78ffe74a7?x-image-process=image/resize,m_fixed,w_180,h_180&k=1779092875211072502","PYTHON PROGRAMMING III YEAR/II SEM MRCET  \nPYTHON PROGRAMMING [R17A0554]  \nLECTURE NOTES  \nB.TECH III YEAR – II SEM (R17)  \n(2019-20)  \nDEPARTMENT OF  \nCOMPUTER SCIENCE AND ENGINEERING  \nMALLA REDDY COLLEGE OF ENGINEERING &  \nTECHNOLOGY  \n(Autonomous Institution – UGC, Govt. of India)  \nRecognized under 2(f) and 12 (B) of UGC ACT 1956  \n(Affiliated to JNTUH, Hyderabad, Approved by AICTE-Accredited by NBA & NAAC – ‘A’ Grade-ISO 9001:2015  \nCertified)  \nMaisammaguda, Dhulapally (Post Via. Hakimpet), Secunderabad – 500100, Telangana State, India  \n\n| PYTHON PROGRAMMING III YEAR/II SEM MRCET\u003Cbr>SYLLABUS\u003Cbr>MALLA REDDY COLLEGE OF ENGINEERING AND TECHNOLOGY |  |  |\n| --- | --- | --- |\n| III Year B. Tech CSE-II SEM\u003Cbr>OPEN ELECTIVE III | L\u003Cbr>3 | T/P/D C- / - / - 3 |\n| (R17A0554) PYTHON PROGRAMMING\u003Cbr>OBJECTIVES:\u003Cbr>􀁸 To read and write simple Python programs.\u003Cbr>􀁸 To develop Python programs with conditionals and loops.\u003Cbr>􀁸 To define Python functions and call them.\u003Cbr>􀁸 To use Python data structures –-lists, tuples, dictionaries.\u003Cbr>􀁸 To do input/output with files in Python.\u003Cbr>UNIT I\u003Cbr>INTRODUCTION DATA, EXPRESSIONS, STATEMENTS\u003Cbr>Introduction to Python and installation, data types: Int, float, Boolean, string, and list; variables, expressions, statements, precedence of operators, comments; modules, functions--- function and its use, flow of execution, parameters and arguments.\u003Cbr>UNIT II\u003Cbr>CONTROL FLOW, LOOPS\u003Cbr>Conditionals: Boolean values and operators, conditional (if), alternative (if-else), chained conditional (if-elif-else); Iteration: while, for, break, continue.\u003Cbr>UNIT III\u003Cbr>FUNCTIONS, ARRAYS\u003Cbr>Fruitful functions: return values, parameters, local and global scope, function composition, recursion; Strings: string slices, immutability, string functions and methods, string module; Python arrays, Access the Elements of an Array, array methods.\u003Cbr>UNIT IV\u003Cbr>LISTS, TUPLES, DICTIONARIES\u003Cbr>Lists: list operations, list slices, list methods, list loop, mutability, aliasing, cloning lists, list parameters, list comprehension; Tuples: tuple assignment, tuple as return value, tuple comprehension; Dictionaries: operations and methods, comprehension;\u003Cbr>UNIT V\u003Cbr>FILES, EXCEPTIONS, MODULES, PACKAGES\u003Cbr>Files and exception: text files, reading and writing files, command line arguments, errors and exceptions, handling exceptions, modules (datetime, time, OS , calendar, math module), Explore packages. |  |  |\n\nPYTHON PROGRAMMING III YEAR/II SEM MRCET  \nOUTCOMES: Upon completion of the course, students will be able to  \n􀁸 Read, write, execute by hand simple Python programs.  \n􀁸 Structure simple Python programs for solving problems.  \n􀁸 Decompose a Python program into functions.  \n􀁸 Represent compound data using Python lists, tuples, dictionaries.  \n􀁸 Read and write data from/to files in Python Programs  \nTEXT BOOKS  \n1.Allen B. Downey, ``Think Python: How to Think Like a Computer Scientist‘‘, 2nd edition, Updated for Python 3, Shroff/O‘Reilly Publishers, 2016.  \n2.R. Nageswara Rao,“Core Python Programming”, dreamtech  \n3. Python Programming: A Modern Approach, Vamsi Kurama, Pearson  \nREFERENCE BOOKS:  \n1. Core Python Programming, W.Chun, Pearson.  \n2. Introduction to Python, Kenneth A. Lambert, Cengage  \n3. Learning Python, Mark Lutz, Orielly  \nPYTHON PROGRAMMING III YEAR/II SEM MRCET  \nINDEX  \n\n| UNIT | TOPIC | PAGE NO |\n| --- | --- | --- |\n| I | INTRODUCTION DATA,\u003Cbr>EXPRESSIONS, STATEMENTS | 1 |\n|  | Introduction to Python and installation | 1 |\n|  | data types: Int | 6 |\n|  | float | 7 |\n|  | Boolean | 8 |\n|  | string | 8 |\n|  | List | 10 |\n|  | variables | 11 |\n|  | expressions | 13 |\n|  | statements | 16 |\n|  | precedence of operators | 17 |\n|  | comments | 18 |\n|  | modules | 19 |\n|  | functions----function and its use | 20 |\n|  | flow of execution | 21 |\n|  | parameters and arguments | 26 |\n| II | CONTROL FLOW, LOOPS | 35 |\n|  | Conditionals: Boolean values and operators, | 35 |\n|  | conditional (if) | 36 |\n|  | alternative (if","cbCaieqIjeUuWDnW","https://ap.wps.com/l/cbCaieqIjeUuWDnW","pdf",1597251,142,"English","# UNIT I - INTRODUCTION DATA, EXPRESSIONS, STATEMENTS\n## Introduction to Python and installation\n## Data types, variables, expressions, statements, precedence of operators, comments\n## Modules, functions, flow of execution, parameters and arguments\n# UNIT II - CONTROL FLOW, LOOPS\n## Conditionals: if, if-else, if-elif-else\n## Iteration: while, for, break, continue\n# UNIT III - FUNCTIONS, ARRAYS\n## Fruitful functions, parameters, local and global scope\n## Function composition and recursion\n## String slices, immutability, string functions and methods, string module\n## Python arrays and array methods\n# UNIT IV - LISTS, TUPLES, DICTIONARIES\n## Lists: operations, slices, methods, loop, mutability, aliasing, cloning, parameters, comprehension\n## Tuples: assignment, return value, comprehension\n## Dictionaries: operations, methods, comprehension\n# UNIT V - FILES, EXCEPTIONS, MODULES, PACKAGES\n## Text files: reading and writing, command line arguments\n## Errors and exceptions: handling exceptions\n## Modules (datetime, time, OS, calendar, math) and exploring packages","[{\"question\":\"What topics are covered in Unit I of Python Programming (R17A0554)?\",\"answer\":\"Unit I covers Python introduction and installation, data types (Int, float, Boolean, string, list), variables, expressions, statements, operator precedence, comments, and modules/functions with execution flow, parameters, and arguments.\"},{\"question\":\"How does the course explain control flow and loops?\",\"answer\":\"Unit II focuses on conditionals (if, if-else, if-elif-else) and iteration using while and for, including break and continue statements.\"},{\"question\":\"What file-related and error-handling concepts are included?\",\"answer\":\"Unit V includes reading and writing text files, command line arguments, errors and exceptions, and handling exceptions, along with modules and package exploration.\"}]","PYTHON PROGRAMMING - R17A0554 - Lecture Notes - B.TECH III YEAR II SEM | PDF",1790610657,358,[148,152,156,160,164,168,172,176,180,184,188,193,198,203,208],{"page_no":8,"url":149,"width":150,"height":151},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/6dbc6b21143335ec4aaa7b7e8d07a2a8.webp",983,1272,{"page_no":14,"url":153,"width":154,"height":155},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/5c8357d062e127382449497abbe41106.webp",982,1270,{"page_no":81,"url":157,"width":158,"height":159},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/2cba0640a1bb835844ab1129ee117c03.webp",981,1269,{"page_no":19,"url":161,"width":162,"height":163},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/7e8393f97c4b9ad8e48feab04e84dd4a.webp",980,1268,{"page_no":24,"url":165,"width":166,"height":167},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/2357e27f2f7c65b7a44e5c11bf32a2f1.webp",979,1267,{"page_no":29,"url":169,"width":170,"height":171},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/36d995ee30a383a75617db0a4d8c76f9.webp",978,1265,{"page_no":34,"url":173,"width":174,"height":175},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/ea12940a21105147a9242088645a3c3f.webp",977,1264,{"page_no":39,"url":177,"width":178,"height":179},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/a6ca1aef6a77181e8dc49b0905647e75.webp",976,1263,{"page_no":44,"url":181,"width":182,"height":183},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/e0a5a6ecb43ceee970275fefe8b43695.webp",975,1261,{"page_no":52,"url":185,"width":186,"height":187},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/34b93de85c2576c718a7977d2787e74f.webp",974,1260,{"page_no":189,"url":190,"width":191,"height":192},11,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/0741649eda125bde71562fb35546aeb0.webp",973,1259,{"page_no":194,"url":195,"width":196,"height":197},12,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/078e745361aeebf467a8b4023eec2b0e.webp",972,1257,{"page_no":199,"url":200,"width":201,"height":202},13,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/3a4f93d6e7c7938ac80cebca24dc6af9.webp",971,1256,{"page_no":204,"url":205,"width":206,"height":207},14,"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/f2eac359310d502c39aee2533ea53928.webp",970,1255,{"page_no":105,"url":209,"width":210,"height":211},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-17/6cf5eb2f927a8c5b035dc97122e3af3f.webp",969,1254,{"list":213,"token":66},[214,221,227,233,240,246,252,258,264,271],{"doc_id":215,"doc_title":216,"file_type":138,"home_preview_img_url":217,"slug":218,"view_count":219,"category_name":30,"create_tm":220},671794,"Python Tutorial - Release 3.7.0","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229988403939/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=0TeUGlu%2Fa0PFFWSmNTr2vqWT%2FfE%3D","python-tutorial-release-370",16,1793580648,{"doc_id":222,"doc_title":223,"file_type":138,"home_preview_img_url":224,"slug":225,"view_count":44,"category_name":30,"create_tm":226},697948,"Data Structures Using Python - R20A0503 - Lecture Notes","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230010141008/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=tlf1pdfBx9k1rFX6Hg0v4tE1y%2FA%3D","data-structures-using-python-r20a0503-lecture-notes",1794446274,{"doc_id":228,"doc_title":229,"file_type":138,"home_preview_img_url":230,"slug":231,"view_count":34,"category_name":30,"create_tm":232},692229,"A Beginners Guide to Python 3 Programming","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230003011037/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=yQdDXy0K0Ca6XsWIQatSvC0esEs%3D","a-beginners-guide-to-python-3-programming-692229",1794186373,{"doc_id":234,"doc_title":235,"file_type":138,"home_preview_img_url":236,"slug":237,"view_count":238,"category_name":30,"create_tm":239},347398,"PROGRAMMING IN “C” - MCA 101 - Lecture Notes","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229911501616/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=vWTWzs3TTGntrdXX3sZTCNO3iJo%3D","programming-in-c-mca-101-lecture-notes",34,1790066783,{"doc_id":241,"doc_title":242,"file_type":138,"home_preview_img_url":243,"slug":244,"view_count":19,"category_name":30,"create_tm":245},685640,"Programming Language Principles and Paradigms - Release 0.4 - Notes","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229999084377/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=leLDmfzqid2NJjdSk0uHj4swnRE%3D","programming-language-principles-and-paradigms-release-04-notes",1794016120,{"doc_id":247,"doc_title":248,"file_type":138,"home_preview_img_url":249,"slug":250,"view_count":52,"category_name":30,"create_tm":251},692230,"Python Handbook - Updated October 14, 2026","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230003011060/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=AjXzDJI3sfPr0oWGSgjKQl%2BgnfQ%3D","python-handbook-updated-october-14-2026",1794186375,{"doc_id":253,"doc_title":254,"file_type":138,"home_preview_img_url":255,"slug":256,"view_count":29,"category_name":30,"create_tm":257},670918,"The Python Cheat Sheet - Quick Reference","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229988353374/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=r73%2BTF72anqGNFIqANHQhDUf6yQ%3D","the-python-cheat-sheet-quick-reference",1793572702,{"doc_id":259,"doc_title":260,"file_type":138,"home_preview_img_url":261,"slug":262,"view_count":24,"category_name":30,"create_tm":263},685779,"Topic 6 - Lists, Sets, Tuples, Dictionaries","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230000203959/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=qEI9HU90gcNKyKXS2QH0n7mJiLA%3D","topic-6-lists-sets-tuples-dictionaries",1794018231,{"doc_id":265,"doc_title":266,"file_type":138,"home_preview_img_url":267,"slug":268,"view_count":269,"category_name":30,"create_tm":270},19157,"C++ & Python for Beginners","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229709434556/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=A9fKTHyqGyf4CN2LdIyN7qoQ81c%3D","c-python-for-beginners",65,1777154415,{"doc_id":272,"doc_title":273,"file_type":138,"home_preview_img_url":274,"slug":275,"view_count":105,"category_name":30,"create_tm":276},391232,"Python Interview Questions - List vs Tuples - Key Features","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229917654344/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796110919&Signature=MM%2FkiGA0f1nt3%2BIz1cXZT%2B%2FAnrs%3D","python-interview-questions-list-vs-tuples-key-features",1790350253]