Name
look
Synopsis
look *fh
, key
, dict
, fold
Description
Performs string search and sets the position in filehandle fh to the first line with a key equal to or greater than key. Returns the new file position, or -1 in case of error. Takes the following arguments:
- fh
Filehandle of the dictionary file.
- key
Key to search for.
- dict
If true, searches in dictionary order, considering only word characters and whitespace.
- fold
If true, ignore case.
Get Perl in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.