Funny I also selected "hello" and "world" above! Xo
My system is also written in Java btw!
Here are example results of my word search:
http://root.rupy.se/node/data/word/four
http://root.rupy.se/node/data/word/only
etc.
But yeah, in short pseudocode:
for url in range-for-"hello": if binary-search (range-for-"world", url): yield url
But yeah, in short pseudocode:
I do use streams, but that is the bare essence of it.