I'm in the process of working with @arati_mejdal, ryan gilmore, and @jules parris to put together a monthly Scripting Challenge post that will start the beginning of next month. I'm opening this up to everyone although scoring will only be kept for non-staff folks (I might be convinced to keep a separate staff leader board). I'm giving you folks an advanced look hoping that some of you will submit prior to it's official launch. This will help me work out any unforeseen problems with the challenge. In addition, one of the bonus scoring criteria will be submitting a script that's faster than anything by the staff. Below is the first challenge. I've attached the dictionary to this post. Comments and questions appreciated.
I love a good word puzzle. This challenge is inspired by Spelling Bee in the New York Times. In it, you must create words from a list of seven letters with the condition that one of the letters is always used. The other letters can be used once, more than once, or not at all. I am modifying the conditions to make things a bit trickier.
Given seven letters, find:
- The longest word using all seven letters and only those seven letters. Letters may be used more than once.
- The longest word using all seven letters and any other letters.
- The longest word using all seven letters and any other letters where no letter from the set of seven is used more than once.
- The longest word in which 5 of the 7 letters appears. Any letter including those outside the 7 may appear once or more except the two unused letters which may not appear at all.
Scripts must accept a list of seven lower case alphabetical characters (a-z) strings that will be stored in a global variable named letterSetList. All scripts will be tested on the same three seven-letter sets. All words will be taken from the dictionary posted below. You may assume it will be opened as a JMP Data Table when your script executes.