What is the use of string function strtonum(string)?
Answer Posted / quickmist
strtonum() will reliably convert a string representation of a number into an integer number. It's reliable because you can pass the min and max value that the you want the input to be within and strtonum() will return an error code if the number falls outside the specified range. This function however expects only 1 '-' symbol to exist in the input and returns a long long integer.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Write a command to rename the files in a directory with "_new" as postfix?
What are Assignment Operators?
What are Unary arithmetic operators?
How to generate random numbers in AWK?
What is the use of PRINTF?
What is the use of string function substr(string,position) in AWK?
Write a command to print first and last line using sed command?
Write a command to find the sum of bytes (size of file) of all files in a directory?
What is the use of string function tolower(string)?
How do you Explicit File output?
What is the use of string function length(string) in AWK?
How to execute an AWK script?
what are divisions main frems
How to display even number of records into one file and odd number of records into another file?
Write a command to print the line number before each line?