Purchase Solution

Java / C# Programming Help

Not what you're looking for?

Ask Custom Question

I have no idea in doing the following:

Create new salary object based on the gross salary
Store new salary object in array
Check if the new gross salary is the new minimum and update accordingly
Check if the new gross salary is the new maximum and update accordingly

Please see the attachemnts for details.

Purchase this Solution

Solution Summary

The new salary object based on the gross salary is created. The new minimum and updated accordingly is found.

Solution Preview

when you create Salary class, try to create a struct in the header file which contains all information. for example,

struct salary
{float grossSalary,
cpp,
ei,
pTax,
fTax,
netSalary;
}s[50];

you can have it outside class declaration almost like global.

Then in payroll class where you invoke the main function, the C++ code may be like the following

#include <iostream.h>
#include "Salary.h"
#include <math.h>

// Main( ) provides the entry point for the program. It does not
// accept any command-line arguments nor does it return a value to
// the calling program.

void Main( )
{
cout << " Welcome to the Salary calculator program " << endl << endl;
int num;
Salary sal;
float min =100000000.0;
float max =-1000000.0;
float grossSalary = ...

Purchase this Solution


Free BrainMass Quizzes
Basic Networking Questions

This quiz consists of some basic networking questions.

C++ Operators

This quiz tests a student's knowledge about C++ operators.

Basic UNIX commands

Use this quiz to check your knowledge of a few common UNIX commands. The quiz covers some of the most essential UNIX commands and their basic usage. If you can pass this quiz then you are clearly on your way to becoming an effective UNIX command line user.

Word 2010: Table of Contents

Ever wondered where a Table of Contents in a Word document comes from? Maybe you need a refresher on the topic? This quiz will remind you of the keywords and options used when working with a T.O.C. in Word 2010.

Basic Computer Terms

We use many basic terms like bit, pixel in our usual conversations about computers. Are we aware of what these mean? This little quiz is an attempt towards discovering that.