Files
calc/help/ishash
2017-05-21 15:38:25 -07:00

37 lines
704 B
Plaintext

NAME
ishash - whether a value is a hash state
SYNOPSIS
ishash(x)
TYPES
x any
return integer
DESCRIPTION
The value returned by ishash(x) is:
0 if x is not a hash state,
1 if x is a sha hash state,
2 if x is a sha1 hash state,
3 if x is a md5 hash state.
EXAMPLE
> a = shs(0), b = shs1(0), c = md5(0)
> print ishash(0), ishash(a), ishash(b), ishash(c);
0 1 2 3
LIMITS
none
LIBRARY
none
SEE ALSO
sha, sha1, md5,
isassoc, isatty, isblk, isconfig, isdefined, iserror, iseven, isfile,
isident, isint, islist, ismat, ismult, isnull, isnum, isobj,
isobjtype, isodd, isprime, isrand, israndom, isreal, isrel,
issimple, issq, isstr, istype