![]() |
|
|
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 |
| Perl: Search for string on line then compare numbers! | Crypto | Shell Programming and Scripting | 2 | 01-22-2008 01:50 AM |
| Get real value from real-time systems | iBot | Complex Event Processing RSS News | 0 | 01-14-2008 02:10 AM |
| Compare two arrays in sh or compare two fields | rijeshpp | Shell Programming and Scripting | 0 | 10-31-2007 02:47 AM |
| How to Compare Floating point / real numbers | padarthy | Shell Programming and Scripting | 13 | 09-24-2007 09:03 PM |
| compare decimal numbers | tmxps | Shell Programming and Scripting | 5 | 11-02-2005 06:46 PM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
how to compare big real numbers
Hi everyone,
I need to compare 2 big Floating/Real numbers in a script. After the comparission it is showing worng values in my script. echo "Enter value1" read value1 echo "Enter value2" read value2 Result=`echo "if($value1 > $value2) 1" | bc` if [ $Result -eq 1 ]; then echo "$value1 is greater" fi Please correct this code .. |
|
||||
|
how to compare big real numbers
Hi everyone,
I need to compare 2 big Floating/Real numbers in a script. After the comparission it is showing worng values in my script. echo "Enter value1" read value1 echo "Enter value2" read value2 Result=`echo "if($value1 > $value2) 1" | bc` if [ $Result -eq 1 ]; then echo "$value1 is greater" fi Please correct this code .. |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|