Kambo company pays employee Gratuity on retirement that can be computed using the Formula Gratuity=(SalaryFixed RateNumber of Years Worked)+One month Salary. Formulate an algorithm that can be used to calculate the gratuity and write a c++ program that can be used for the computation.

Show us your code and we'll show you ours! :P
Check out the community rules, particularly this rule:

  • Do provide evidence of having done some work yourself if posting questions from school or work assignments

In your post, you have provided no evidence that you have done anything towards this assignment/project. You should know that the community here does not exist to do your homework for you. We are merely here to help guide you when you have problems.

The best advice I can give you ATM is this:
You have a pretty well defined problem set, it's not particularly difficult. Just sit back, take another look at the problem, have a bit of a think and break it down into a sequence of logical steps that you can translate into code. Then write your code and see what happens when you try compiling and running it!

Once you've done this, if you have any problems with your code, please post again. And when you do so, please ensure you include the following:

  • A description of the problem/s you are encountering
  • A short snippet of problematic code
  • Any error messages from the compiler
  • Any other useful, relevant information that you think might help us to help you!

:)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.