Python Programs for printing pyramid patterns
Python Programs for printing pyramid patterns (Using for loop/ nested for loop) Pattern-1 for i in range(1,6): for j in range(i): print(" * ", end = "") print( ) Output: * * * * * * * * * * * * * * * Pattern-2 for i in range(5,0,-1): for j…
Python while loop exercises for CBSE Computer Science
Python while loop exercises for CBSE Computer Science 1- Python program to print First 10 Even numbers using while loop num = 2 while(num<=20): print(num) num = num + 2 Output: 2 4 6 8 10 12 14 16 18 20 2- Python program to print…
What is tkinter in python
What is tkinter in python? Tkinter is a standard GUI (Graphical User Interface) library for Python. It is a built-in module that comes with Python and allows programmers to create windows, dialogs, buttons, menus, and other GUI elements for their Python…
Using of Datetime Library in python Class 11-12 Notes
Using of Datetime Library in python Class 11-12 Notes As python provides a large set of library, it also contains datetime library. This library displays the date in YYYY-MM-DD format. Python datetime module handles the extraction and formatting of date…
Data File Handling in Python Class 12 Notes
Python File Handling Notes for class 12 Data File Handling in Python Data maintained inside the files is termed as persistent data. It means it is permanent in nature. Python allow us to read data from and save data to external text files…
Working with Functions in Python Class 12 Notes
Working with Functions in Python Class 12 Notes Working with Functions in Python Class 12 Notes: Here you will learn about the functions in Python, Types of Functions in Python, How to create a function in Python, how function works in Python. These…
JUMP Statements in Python for Class 12
JUMP STATEMENTS Looping allows a user to program and repeat tasks efficiently. In certain situations, when some particular condition occurs, a user may want to exit from a loop (come out of the loop forever) or skip some statements of the loop before…
For loop in Python Notes for Class 11 and 12
For loop in Python The for statement is used to iterate/repeat itself over a range of values or a sequence. The for loop is executed for each of these items in the range. These values can be either numeric, or, as we shall see in the successive chapters,…
While Loop In Python Notes for Class 11-12
While Loop In Python: A while loop in Python is used to execute a block of code repeatedly until a certain condition is met. Here is the basic syntax of a while loop: while condition: # code to be executed The condition is checked at the beginning…
Decision Making in Python
Decision Making in Python for Beginners (CBSE Class 11-12) Introduction to Decision Making in Python Welcome, CBSE Class 11-12 students! Decision making in Python is like giving your computer a brain to make choices. It’s about telling Python, “Bhai,…