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
1.  Develop HTML code to create a Web page with the red background and title "My First Page" in any other color. 2.  Develop an HTML document with details of your name, telephon

What are Attributes in HTML langauge? A few tags have attributes. An attribute is a name, followed through an = sign, followed by the value. For instance, to make a centered H1

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

Need help with a cobol program.

Computers and Programming Concept 1. Classify computer systems according to capacity. How they are different from computers according to the classification of technology. Provi

Advantages of visual basic programming language Visual Basic is an exclusive selection language published by Microsoft Company, so programs published in Visible Basic cannot, e

need a program of any multiplication algorithm implemented in assembly language x86 without using mul command

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


After studying the concept, terminology, and implementation of CSS stylesheets, create a stylesheet to accompany your solutions to Question 1. A rich collection of styles should be