Learn about Python Program to Find the Average of Three Numbers in the below code example. Also refer the comments in the code snippet to get a detailed view about what’s actually happening.
Python Program to Find the Average of Three Numbers
# Python program to find average of three numbers num1 = 5 num2 = 10 num3 = 20 # calculate average avg = (num1 + num2 + num3)/3 #print result print('The average of numbers = %0.2f' %avg)
The average of numbers = 11.67
Hope above code works for you and Refer the below Related Codes to gain more insights. Happy coding and come back again.
Similar Code : Program to find Average of Two Numbers using a Loop Python