![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Help with arithmetic operation | emjayshaikh | Shell Programming and Scripting | 3 | 09-23-2007 11:44 PM |
| Can I use wc -l with arithmetic expression? | lalelle | Shell Programming and Scripting | 3 | 08-11-2007 06:44 PM |
| Arithmetic In UNIX | tygun | UNIX for Dummies Questions & Answers | 3 | 11-23-2005 05:46 PM |
| arithmetic syntax | paprbagprincess | UNIX for Dummies Questions & Answers | 1 | 05-11-2004 08:30 AM |
| time arithmetic | csong2 | UNIX for Advanced & Expert Users | 2 | 11-28-2001 11:57 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
arithmetic in ksh
Helloo..
I am trying one very simple thing I could not find anything on google.. I have 2 integer variable..and I need to do division...in ksh where $catch and $num are integer variable.. I tryed with this: printf "%0.2f" $final=$catch/$num but it does not work.. any help is welcome.. |
|
||||
|
Rightttt but this is not wanted result..
I tryed also bc I forgot to mention that.. but my $catch is 14 $num is 100 it is defined above in program.. result should be 0,14 also I tryed this: x=`echo $catch / $num | bc` echo $x but this does not give goot results.. |
|
||||
|
Quote:
|
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|