[HPADM] Getting an absolute value
- From: "Shaw, Marco" <Marco.Shaw@xxxxxxxxx>
- Date: Thu, 12 Oct 2006 11:38:07 -0300
Can't believe google doesn't provide an answer, searched these archives
also!
#a=`expr 2 - 1`
#echo $a
1
#a=`expr 2 - 3`
#echo $a
-1
I want to get the absolute value of the difference. I don't have to use
expr, but
also would prefer something available directly with the Borne shell.
Marco
--
---> Please post QUESTIONS and SUMMARIES only!! <---
To subscribe/unsubscribe to this list, contact majordomo@xxxxxxxxxxxxx
Name: hpux-admin@xxxxxxxxxxxxx Owner: owner-hpux-admin@xxxxxxxxxxxxx
Archives: ftp.dutchworks.nl:/pub/digests/hpux-admin (FTP, browse only)
http://www.dutchworks.nl/htbin/hpsysadmin (Web, browse & search)
- Follow-Ups:
- [HPADM] RE: Getting an absolute value
- From: COUPRIE Kees
- [HPADM] RE: Getting an absolute value
- Prev by Date: [HPADM] SUMMARY: Getting the date from the number of seconds since epoch
- Next by Date: [HPADM] RE: Getting an absolute value
- Previous by thread: [HPADM] SUMMARY: Getting the date from the number of seconds since epoch
- Next by thread: [HPADM] RE: Getting an absolute value
- Index(es):
Relevant Pages
|
|