Calculate the sha1 hash of a string. Calculates the sha1 hash of str using the US Secure Hash Algorithm 1, and returns that hash. The hash is a 40-character hexadecimal number.
Return value:
Returns the sha1 hash as a string encapsulating a hex number.
Example
import standard.lib.cripto
class Main {
function Main() {
echo "The sha1 hash of 'test' is : "+sha1("test");
}
}
Results
The sha1 hash of 'test' is : a94a8fe5ccb19ba61c4c0873d391e987982fbbd3