















v


   Purpose: Read in a sentence as a list of words.

:- public
	read_in/1.

:- m
	read_in(?),
	ri_rest(+, -),
	ri_word(-, ?, ?),
	ri_words(-, ?, ?),
	ri_let
-, ?, ?),
	ri_space(?, ?),
	ri_digits(-, ?, ?),
	ri_digit(+),
	ri_lcase
-).



%   read_in(Words)
%   reads characters until it finds a per
(. ? or !) at the end of a
%   line, that is, followed by any n
r of spaces but nothing else.
%   It then parses this li


































































































































 C=63),			%  ! . ?
	repeat, get0(C1), C1 =
2, !,		%  next non-blank
	(   C1 = 31,
Chars = []		%  was end of line
	; 
ars = [C1|Chars1], ri_rest(C1,
rs1)
	).					%  false alar
_rest(C, [C1|Chars]) :
%  all control cha
C =< 32, !,			
act as spa

	get(
		































































































































































































































C =< 57.	%  0..9

ri_letter(C, C) :-
	C >= 9
 =<
, !.	%  a..z
ri_letter(C, D) :-
	C >= 65, C =< 90,	%  A..Z
	D is C+32.		%  32 is "a"-"A"

C])}.			%  is punctuation


