Dictionaries are another data type that supports a {key: value} structure. Creating a dictionary is...
Category - Python
Body Mass Index Code in Python
Python program to calculate Body Mass Index (BMI) The Body Mass Index (BMI) is a quick way to...
Calculate Average of N Numbers Entered by User in Python
The program takes the elements of the list one by one and displays the average of the elements of...
How is string formatting done through the % operator in Python
Formatting output using String modulo operator(%) The % operator can also be used for string...
Python format() Method Examples
String Format Python Example To make sure a string will display as expected, we can format the...
floor() Method in Python with Examples
In this tutorial, we’ll learn how to use the floor() method in Python. floor() method in...
ceil() Method in Python with Examples
In this tutorial, we’ll learn how to use the ceil() method in Python. Python number method...
abs() Method in Python
Python number method abs() returns absolute value of x – the (positive) distance between x...
Python Conditions and If statements with Examples
Conditions are an essential concept in programming. For example, a variable is positive, another...
Program to find absolute value of an input number in Python
How to calculate absolute value in python To get the absolute value of a number in python there is...
Write a program to delete duplicate elements from an array in Python
Write a program to delete duplicate elements from an array in Python. Python Code: # Python code to...
Python Program to Check Prime Number using While Loop
In this post, we will write a program in Python to check whether the input number is prime or...
Reverse an Integer in Python 3
Python Script program to reverse the number entered by the user, then displays the reversed number...