Correctly parsing "light light light"

How about this?

The Boring Room is a room. The Boring Room is dark.
A light is a kind of device. A light can be lit. Understand "light" as a light when the snippet-so-far does not include "light".
A light light is a privately-named light in the Boring Room. Understand "light" as the light light.
A heavy light is a privately-named light in the Boring Room. Understand "heavy" as the heavy light.
The heavy light is switched on and lit.

Before burning a light: instead try switching on the noun.
Carry out switching on a light: now the noun is lit.
Carry out switching off a light: now the noun is unlit.

Test me with "light light / light / light light light".

To decide which snippet is snippet-so-far:
	(- (SnippetSoFar()) -).

Include (-

[ SnippetSoFar ;
	if (wn == match_from)
		return 100;
	else
		return (match_from*100)+(wn-match_from);
];

-).
5 Likes