A company decides to give bonus to all its employees on Diwali. A 5% bonus on salary is given to the male workers and 10% bonus on salary to the female workers. Write a python program to enter the salary of the employees and sex of the employee. If the salary of the employee is less than Rs. 10,000 then the employees gets an extra 2% bonus on salary. Calculate the bonus that has to be given to the employee and display the salary that the employee will get.



                                        Write a python program to determine whether a person is eligible to vote.

A company decides to give bonus to all its employees on Diwali. A 5% bonus on salary is given to the male workers and 10% bonus on salary to the female workers. Write a python program to enter the salary of the employees and sex of the employee. If the salary of the employee is less than Rs. 10,000 then the employees gets an extra 2% bonus on salary. Calculate the bonus that has to be given to the employee and display the salary that the employee will get.

PROGRAM:

 a=int(input("Enter your salary:"))

s=str(input("Enter your sex (Male/Female):"))

print("************************************************************************")

if (s=="Male"):

    print("Your special salary due to diwali festival:"+"Rs.", a+(a*(5/100)))

if (s=="Female"):

    print("Your special salary due to diwali festival:"+"Rs.", a+(a*(10/100)))

if (s=="Male" and a<10000):

    print("And also based on your salary:"+"Rs.", a+(a*(7/100)))

if (s=="Female" and a<10000):

    print("And also based on your salary:"+"Rs.", a+(a*(12/100)))

print("-------------------By infinitynotes00(∞).blogspot.com-----------------------------")


OUTPUT:

No comments:

Post a Comment




Copyright Ⓒ 2022 | Mechpedia | All Right Reserved.