<commit_before># Merge prefixes with matching words!

These implementations will do a filtered merge, given two lists:
One of **sorted** words, one of **sorted** shorter-length prefixes.
Elements in either list will only make it into the final merged
list if:

* A word has a matching prefix
* A prefix has no matching word

They will be added in order of their appearance so they will be
automatically sorted thusly.

# How exactly?

First a [Trie](http://en.wikipedia.org/wiki/Trie) was constructed to
ease evaluation of each source word. From here:

* Each prefix is tried
  - If the first prefix matched then we 'cache' (0 index)
     + Remove it from the prefix list
     + continue its use until a new match is found
  - If, however the matching prefix isn't at 0 index
  	 + append all leading prefixes to the final list
     + remove them from the prefix list
* Do a final check for trailing prefixes in the prefix list
  - Add ones we don't already have

# Languages

Currently written in:

* Java
* Ruby

With their implementations residing in their respective directories.

# Author

<NAME>
http://jphenow.com
Contact me if you have any questions or concerns.
<commit_msg>Fixed author section formatting<commit_after># Merge prefixes with matching words!

These implementations will do a filtered merge, given two lists:
One of **sorted** words, one of **sorted** shorter-length prefixes.
Elements in either list will only make it into the final merged
list if:

* A word has a matching prefix
* A prefix has no matching word

They will be added in order of their appearance so they will be
automatically sorted thusly.

# How exactly?

First a [Trie](http://en.wikipedia.org/wiki/Trie) was constructed to
ease evaluation of each source word. From here:

* Each prefix is tried
  - If the first prefix matched then we 'cache' (0 index)
     + Remove it from the prefix list
     + continue its use until a new match is found
  - If, however the matching prefix isn't at 0 index
  	 + append all leading prefixes to the final list
     + remove them from the prefix list
* Do a final check for trailing prefixes in the prefix list
  - Add ones we don't already have

# Languages

Currently written in:

* Java
* Ruby

With their implementations residing in their respective directories.

# Author

<NAME>

http://jphenow.com

Contact me if you have any questions or concerns.

{'fraction_non_alphanumeric': 0.055322715842414084, 'fraction_numerical': 0.0016764459346186086, 'mean_word_length': 3.736111111111111, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5639324', 'n_tokens_mistral': 651, 'n_tokens_neox': 631, 'n_words': 359}