xHarbour Reference Documentation > Function Reference xHarbour Developers Network  

Sign()

Converts the sign of a number to a numeric value.

Syntax

Sign( <nNumber> ) --> nSign

Arguments

<nNumber>
Any numeric value can be passed.

Return

The function returns -1 for negative numbers, 0 for zero, and +1 for positive numbers.

Info

See also:Abs()
Category: CT:Math , Mathematical functions
Source:ct\ctmath2.c
LIB:xhb.lib
DLL:xhbdll.dll


Copyright © 2006-2007 xHarbour.com Inc. All rights reserved.
http://www.xHarbour.com
Created by docmaker.exe