Chapter 6. Performing Arithmetic

   

Korn Shell: Unix and Linux Programming Manual, Third Edition, The
By Anatole Olczak

Table of Contents


The let Command

The ((...)) Command

Declaring Integer Variables

Arithmetic Constants

Arithmetic Operators

Random Numbers

The Korn shell provides the ability to perform integer arithmetic in any base from two to thirty-six using built-in commands. It executes much faster than using the expr command, since it doesn't have to start another process. It can also be used instead of the test command for integer comparisons. In addition, all of the operators from the C programming language (except ++, , and ?:) are now supported by the Korn shell.


       
    Top
     



    Korn Shell. Unix and Linux Programming Manual, Third Edition
    Korn Shell. Unix and Linux Programming Manual, Third Edition
    ISBN: N/A
    EAN: N/A
    Year: 2000
    Pages: 177

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net