% -*- texinfo -*- % @deftypefn {Function File} {} substr (@var{s}, @var{offset}, @var{len}) % Return the substring of @var{s} which starts at character number % @var{offset} and is @var{len} characters long. % % If @var{offset} is negative, extraction starts that far from the end of % the string. If @var{len} is omitted, the substring extends to the end % of S. % % For example, % % @example % @group % substr ('This is a test string', 6, 9) % @result{} 'is a test' % @end group % @end example % % This function is patterned after AWK. You can get the same result by % @code{@var{s}(@var{offset} : (@var{offset} + @var{len} - 1))}. % @end deftypefn