The stupid question is the question not asked | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
If the idea is to permit non-profane uses of words that have profane uses, you can't do it without a far greater level of artificial intelligence that can be achieved with regexps alone (would need instead to use very simple regexps to feed a correspondingly heavyweight parser plus a some kind of meaning analyser). For example, "Cock your rifle" could be a valid sentence related to the biathlon.
And then there's the fact that you say "a lot of ..." rather than "exclusively" suggesting there might be other allowable topics of discussion that use ambiguous words when considered singly which you want to let through. Therefore it seems to me that the stated goal is infeasible and can best be exchanged for a feasible one like checking for words which only have a profane meaning or taking on the (far) greater burden of analysing meaning rather than syntax. -M Free your mind In reply to Re: Regex solution needed
by Moron
|
|