Professional Documents
Culture Documents
htm
Home Programming Java Web Databases Academic Management Quality Telecom More...
Advertisements
There are various operators supported by each shell. Our tutorial is based on default shell (Bourne) s
we are going to cover all the important Bourne Shell operators in the tutorial.
Unix - File Permission The Bourne shell didn't originally have any mechanism to perform simple arithmetic but it uses externa
programs, either awk or the must simpler program expr.
Unix - Environment
Here is simple example to add two numbers:
Unix - Basic Utilities
Unix - Shell Loops Assume variable a holds 10 and variable b holds 20 then:
1 of 4 23-Feb-15 9:37 PM
Unix - Shell Basic Operators http://www.tutorialspoint.com/unix/unix-basic-operators.htm
Unix Useful Resources Not Equality - Compares two numbers, if both are
!= [ $a != $b ] would return true.
different then returns true.
Unix - Useful Commands
It is very important to note here that all the conditional expressions would be put inside square braces wit
Unix - Quick Guide one spaces around them, for example [ $a == $b ] is correct where as [$a==$b] is incorrect.
Unix - Builtin Functions All the arithmetical calculations are done using long integers.
Unix - System Calls
Selected Reading For example, following operators would work to check a relation between 10 and 20 as well as in betwee
"10" and "20" but not in between "ten" and "twenty".
Developer's Best Practices
Assume variable a holds 10 and variable b holds 20 then:
Effective Resume Writing
Show Examples
Computer Glossary
It is very important to note here that all the conditional expressions would be put inside square braces wit
one spaces around them, for example [ $a <= $b ] is correct where as [$a <= $b] is incorrect.
2 of 4 23-Feb-15 9:37 PM
Unix - Shell Basic Operators http://www.tutorialspoint.com/unix/unix-basic-operators.htm
Show Examples
Show Examples
There are following operators to test various properties associated with a Unix file.
Assume a variable file holds an existing file name "test" whose size is 100 bytes and has read, write and
execute permission on:
Show Examples
3 of 4 23-Feb-15 9:37 PM
Unix - Shell Basic Operators http://www.tutorialspoint.com/unix/unix-basic-operators.htm
C Shell Operators
Following link would give your brief idea on Korn Shell Operators.
Advertisements
ASP.NET | jQuery | AJAX | ANT | JSP | Servlets | log4j | iBATIS | Hibernate | JDBC | Struts | HTML5 |
4 of 4 23-Feb-15 9:37 PM