A developper has to code in e*Gate the following rule :
"take the 20 first characters of a string".
He say me that he use a substring function and that this function launch an exception if the initial string has less than 20 characters. For me the function should return the whole string if it is smaller than 20.
Is it a "normal" behaviour of the substring function or is it a bad use made by the developper ?
Thanks by advance.
"take the 20 first characters of a string".
He say me that he use a substring function and that this function launch an exception if the initial string has less than 20 characters. For me the function should return the whole string if it is smaller than 20.
Is it a "normal" behaviour of the substring function or is it a bad use made by the developper ?
Thanks by advance.