Print 12 pens cost price in Python
print() - Question 13
In this question, we will see how to print the cost of 12 pens if the cost of one pen is Rs. 14 in python programming using the print() function. To know more about print() function click on the print() function lesson.
Q13) Write a program in python to print the cost of 12 pens if the cost of one pen is Rs. 14.
Program
print('Cost of 1 pen = Rs.14')
print('Cost of 12 pens = Rs.{}'.format(12*14))
Output
Cost of 1 pen = Rs.14 Cost of 12 pens = Rs.168