Python Online Compiler
Example: Python program to enter the P, T, R, and calculate its Simple Interest
C
C++
C#
Java
Python
PHP
main.py
STDIN
Run
# Python program to enter the P, T, R, and calculate its Simple Interest print("Enter the principal (amount), time, and rate::") p, t, r, SI = float(input()), float(input()), float(input()), None # p = principal # t = time # r = rate # SI = simple interest # Calculate simple interest SI = (p * t * r) / 100 # Output print("Simple Interest = ", SI)
5 7 9
Output
Clear
ADVERTISEMENTS