0% found this document useful (0 votes)
11 views2 pages

Python Programming Course Overview

The OE501 Python Programming course covers fundamental concepts of Python including syntax, functions, data structures, and file handling. It includes practical applications such as web scraping and working with Excel spreadsheets. The course is supported by various textbooks and reference materials for comprehensive learning.

Uploaded by

suniltiwari0501
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views2 pages

Python Programming Course Overview

The OE501 Python Programming course covers fundamental concepts of Python including syntax, functions, data structures, and file handling. It includes practical applications such as web scraping and working with Excel spreadsheets. The course is supported by various textbooks and reference materials for comprehensive learning.

Uploaded by

suniltiwari0501
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

OE501 - Python Programming

Course Outcomes:
The course will enable students to:
1. Learn the syntax and semantics of Python Programming Language.
2. Write Python functions to facilitate code reuse and manipulate strings.
3. Illustrate the process of structuring the data using lists, tuples and dictionaries.
4. Demonstrate the use of built-in functions to navigate the file system.

Unit –I
Introduction, Python Basics
Entering Expressions into the Interactive Shell, The Integer, Floating-Point, and String Data Types, String
Concatenation and Replication, Storing Values in Variables, You’re First Program, Dissecting Your
Program.
Flow control: Boolean Values, Comparison Operators, Boolean Operators, Mixing Boolean and
Comparison Operators, Elements of Flow Control, Program Execution, Flow Control Statements,
Importing Modules, Ending a Program Early with [Link]().

Unit –II

Functions: def. Statements with Parameters, Return Values and return Statements, The None
Value, Keyword Arguments and print(), Local and Global Scope, The global Statement.

Unit –III
Dictionaries and Structuring Data
The Dictionary Data Type, Pretty Printing, Using Data Structures to Model Real-World Things.
Manipulating Strings - Working with Strings, Useful String Methods.

Unit –IV
Pattern Matching with Regular Expressions
Finding Patterns of Text without Regular Expressions, Finding Patterns of Text with Regular Expressions,
More Pattern Matching with Regular Expressions, Greedy and No greedy Matching, The find all() Method,
Character Classes, Making Your Own Character Classes, The Caret and Dollar Sign Characters, The
Wildcard Character, Review of Regex Symbols, Case-Insensitive Matching, Substituting Strings with the
sub() Method, Managing Complex Regexes, Combining [Link], re .DOTALL, and re
.VERBOSE.
Reading and Writing Files
78 | P a g e
Files and File Paths, The [Link] Module, The File Reading/Writing Process, Saving Variables with the
shelve Module, Saving Variables with the [Link]() Function.
Organizing Files: The shutil Module, Walking a Directory Tree, Compressing Files with the zipfile Module.

Unit –V
Web Scraping
Project: [Link] with the web browser Module, Downloading Files from the Web with the requests
Module, Saving Downloaded Files to the Hard Drive, HTML.
Working with Excel Spreadsheets: Excel Documents, Installing the openpyxl Module, Reading
Excel Documents, Project: Reading Data from a Spreadsheet, Writing Excel Documents, Project:
Updating a Spreadsheet, Setting the Font Style of Cells, Font Objects, Formulas, Adjusting Rows and
Columns, Charts.

Text Books

1. Latest python Yashavant Kanetkar BPB Publication.


2. Charles Dierbach, "Introduction to Computer Science Using Python", 1st Edition, Wiley
India
Pvt Ltd. ISBN-13: 978-8126556014.
3. Wesley J Chun, “Core Python Applications Programming”, 3rd Edition, Pearson
Education India, 2015. ISBN-13: 978-9332555365.

Reference Books

1. Roberto Tamassia, Michael H Goldwasser, Michael T Goodrich, “Data Structures and


Algorithms in Python”, 1st Edition, Wiley India Pvt Ltd, 2016. ISBN-13: 978-8126562176.
2. ReemaThareja, “Python Programming using problem solving approach”, Oxford
University press, 2017. ISBN-13: 978-0199480173
3. Charles R. Severance, “Python for Everybody: Exploring Data Using Python 3”,
1st Edition, Shroff Publishers, 2017. ISBN: 978-9352136278.

79 | P a g e

Common questions

Powered by AI

The sys.exit() function in Python terminates the current program, allowing for control over program flow and providing a way to exit scripts gracefully when encountering errors or upon completion of necessary tasks. It's essential for handling unexpected situations or managing program termination based on certain conditions .

Python's built-in functions for flow control, which include Boolean and comparison operators, and conditional statements, contribute to robust programming by allowing developers to define clear execution paths based on conditions. Proper use of flow control ensures that scripts handle various input scenarios and exceptions, reduces the risk of errors during execution, and enhances code readability and maintenance .

The openpyxl module allows for reading and writing Excel spreadsheets, making it invaluable for data analysis projects. It provides seamless integration with Excel formats, enabling data manipulation, chart creation, and formula handling within Python scripts, thereby bridging gap between Python-based analytics and traditional spreadsheet software .

Regular expressions in Python enhance text parsing by enabling pattern detection, substitution, and searching within strings which are essential in data extraction tasks such as web scraping and text analysis. Greedy matching refers to the regex operator matching the longest possible string that satisfies the pattern, whereas non-greedy matching, using a '?', matches the shortest possible string, offering flexibility in capturing necessary data without over-collection .

The Python Programming course covers data structures such as lists, tuples, and dictionaries which are crucial for modeling real-world things because they enable the storage and organization of complex data. Lists provide ordered sequences, tuples are immutable collections, and dictionaries store data in key-value pairs, allowing for efficient data retrieval and manipulation, reflecting the way real-world data is often organized .

Python's string manipulation methods offer advanced text handling capabilities, allowing developers to create dynamic and flexible code. Methods for concatenation, case conversion, trimming, and searching foster text processing and formatting tasks, simplifying the development of adaptable scripts that respond to varying content demands, enhancing overall code quality and versatility .

Python provides several mechanisms for managing files, including the os.path module for handling file paths, the shelve module for storing variables, and the shutil module for file operations like compressing with zipfile. These facilitate file organization by allowing programmers to navigate directories, read/write data efficiently, and ensure structured storage, streamlining the handling of files in complex programming projects .

Python's pattern matching through regular expressions is essential in web scraping as it allows for the precise extraction of data from HTML pages. Utilizing the requests module to fetch web pages, regex provides the tools to parse through and identify key data points like links, text, and metadata, enabling effective data gathering from diverse web resources .

The 'def' statement is fundamental for defining functions in Python, facilitating code modularization and reusability. By encapsulating functionality within functions, 'def' promotes organize layered architecture, making it easier to manage large codebases, enhance readability, and reduce redundancy, all of which are crucial in both developing and maintaining software .

Python's use of global and local scope variables enhances efficiency by limiting variable access and providing clear data management within functions or scripts. Global scope allows data to be accessed program-wide, while local scope confines data interaction within functions, preventing accidental data modification and reducing bugs by isolating variable impacts .

You might also like