![]() |
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 |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Converting a String variable into Integer | neeto | UNIX for Dummies Questions & Answers | 2 | 05-22-2008 03:38 PM |
| Subtracting date / timestamps | roadcyclist | Shell Programming and Scripting | 0 | 06-21-2006 02:51 PM |
| Will we get SEGV if we try to “delete []” un-initialized integer pointer variable. | sureshreddi_ps | High Level Programming | 2 | 10-11-2004 06:11 AM |
| capturing the output of grep as integer variable | babariba | UNIX for Dummies Questions & Answers | 2 | 11-16-2001 10:42 AM |
| Subtracting Variables which are commands | Astudent | UNIX for Dummies Questions & Answers | 2 | 03-30-2001 09:55 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Subtracting an Integer from a Variable
Hello,
I am in following situation.- COUNT=`ls -l | wc -l` echo $COUNT ---> 26 NO_OF_FILES=$COUNT-1 echo $NO_OF_FILES ---> 26-1 Here, I want the output to be 25. How could I do this. It seems simple, but I am not getting it. Please help me. |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|