Write a shell script to calculate gross salary, Programming Languages


 Write a shell script  (W.A.S.S) to calculate gross salary.

Program

# Write a shell script  (W.A.S.S) to calculate gross salary.


echo "Enter any Basic Salary"     #echo is a command used to print on Output device
read bs                                        #read is a command used to get input from input device
hra=`expr $bs \* 10 / 100`           # \* is used because * has special meaning
da=`expr $bs \* 15 / 100`            # expr is stands for expression
gs=`expr $bs + $da + $hra`        #calculate sum of basic,hra and da
echo "Gross salary = $gs"                # $gs prints the value stored in variable gs

Output

Gross Salary = Basic + HRA + DA. HRA = 10% and DA = 15%
Enter any Basic Salary
100
Gross salary = 125

Posted Date: 9/26/2012 4:22:26 AM | Location : United States







Related Discussions:- Write a shell script to calculate gross salary, Assignment Help, Ask Question on Write a shell script to calculate gross salary, Get Answer, Expert's Help, Write a shell script to calculate gross salary Discussions

Write discussion on Write a shell script to calculate gross salary
Your posts are moderated
Related Questions
The idea of this section is not to do anything new along with a series solution problem.  Instead this is here to exemplify that moving in a higher order differential equation does

The creation of the menu will involve writing procedural code, using decision logic, writing a loop, and using the case statement.  Although it is not required for grading, it is r

The system you will develop should provide the following functionality to its users.     1.  Your system should allow the users to aggregate three different RSS feeds (they should

You have been employed by a bounty hunter to create hit list (yes... you better do this right). Create a Hit List program that can records the name, bounty, and difficulty for ten

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

Objectives: Create an applet, Use methods from the Graphics class , Use the Color class General Instructions: The java class that need to be imported into this assignm

Question 1 How to call a WML Script from a WML Page? Question 2 Write short notes on WML Script Operators and Expressions Question 3 Write short notes on WML Script Statements

The software development team identified the following classes based on the analysis of given requirements: Product, Employee, ProductList, Supplier. 1.  Identify the relationsh

If it is a weekday and it is not a holiday, then you go to work. However, if it is a weekday and it is a holiday, then what you do depends on the weather. If it is raining, you pla

What is "No_Data_Found" in Oracle?