Unix Shell Script to Calculate Total Pay and Net Pay
Not what you're looking for?
Develop a Unix shell script to input number of hours worked and pay rate and calculate the total pay, then the social security amount (assume 5%), then the net pay. Do this as a loop until the number of hours worked is zero.
Purchase this Solution
Solution Summary
The following script inputs hours worked and pay rate to calculate grossPay. It calculates the social security amount by multiplying the social security rate 5% with the grossPay. Next it deducts this social security amount from the grossPay to calculate the net pay amount. Please remember that bash variables cannot store fractions, so it is wise to use the utility bc instead of bash. However, in this case we have not used "bc".
Solution Preview
The following script inputs hours worked and pay rate to calculate grossPay. It calculates the social security amount by multiplying the social security rate 5% with the grossPay. Next it deducts this social security amount from the grossPay to calculate the net pay amount. Please remember that bash variables cannot store ...
Purchase this Solution
Free BrainMass Quizzes
Java loops
This quiz checks your knowledge of for and while loops in Java. For and while loops are essential building blocks for all Java programs. Having a solid understanding of these constructs is critical for success in programming Java.
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.
C# variables and classes
This quiz contains questions about C# classes and variables.
Javscript Basics
Quiz on basics of javascript programming language.
Inserting and deleting in a linked list
This quiz tests your understanding of how to insert and delete elements in a linked list. Understanding of the use of linked lists, and the related performance aspects, is an important fundamental skill of computer science data structures.