Category Archives: Python Tutorial

Python Local and Global Variables With Example Programs

Task: Python Local and Global Variables With Example Programs – This Python programming tutorial explains the use of Python Local and Global Variables With Example Programs. Using Local and Global Variables in Python Code Local Variables in Python What is a Local Variable in Python? In Python any variable which is defined inside a function… Read More »

Python while loop Syntax Flowchart Example

Python while loop Syntax Flowchart Example – This Python programmingtutorial will explain in a simple and easy to understand way: The while loop statement in Python The Syntax of the while loop The flowchart of while loop The examples and working of while loop The Real Example of while loop The Python progam source code… Read More »

isprime Python Function Efficient Logic

isprime Python Function Efficient Logic – This Python programming tutorial will explain: Definition of a Prime Number with examples Is 1 prime or Composite? Defining a Composite number with examples How to Write isprime python function? Explanatin of the Logic of isprime Python function The source code and output of the python program What is… Read More »

Python math Functions

Python math Functions – This Python tutorial will explain the use of Python math functions in Python Programs with example Python scripts and their output. What is a Python math Module? The Python programming language has a math module. The math module contains different functions for general math calculations. What are different math functions? There… Read More »

Python range Function in for loop

Python range Function in for loop – this python tutorial will explain the purpose and use of Python range() function especially in for loop. The Use of Python range Function in for loop The range function Normally, we use range() function in for loop statemt to execute a block of statements for a specified number… Read More »

Python print function – Printing Output

Python print function – Printing Output – This Python tutorial will explain the use of Python print() function for showing the output on screen in different ways. What is print() function in Python Python print() function is used as an output statement in Python programs. Example of print() function Here is a simple example: print(… Read More »

Python Ternary Operator or Conditional Expressions

Python Conditional Expression is also called Ternary Operator. It is an alternative to a simple Python if else statement. Syntax of Python Ternary Operator or Conditional Expressions x  if   C   else   y Where x is a simple Python expression or statement. The C represents a given condition. The y represents another simple… Read More »