Words containing "the" substring: Difference between revisions
Content added Content deleted
(→{{header|Smalltalk}}: back to previous version; me stupid.) |
m (→{{header|Smalltalk}}: ouch undid one too many...) |
||
Line 671: | Line 671: | ||
{{works with|Smalltalk/X}} |
{{works with|Smalltalk/X}} |
||
<lang smalltalk>'unixdict.txt' asFilename contents |
<lang smalltalk>'unixdict.txt' asFilename contents |
||
select:[:word | (word size > 11) and:[word includesString:'the']] |
select:[:word | (word size > 11) and:[word includesString:'the' caseSensitive:trueOrFalseWhoKnows]] |
||
thenDo:#transcribeCR</lang> |
thenDo:#transcribeCR</lang> |
||
Line 680: | Line 680: | ||
|word| |
|word| |
||
((word := Stdin nextLine) size > 11 |
((word := Stdin nextLine) size > 11 |
||
and:[word includesString:'the'] |
and:[word includesString:'the' caseSensitive:trueOrFalseWhoKnows] |
||
) ifTrue:[ |
) ifTrue:[ |
||
Stdout nextPutLine: word |
Stdout nextPutLine: word |