All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > General > Word Problems
Splitting words (Posted on 2005-07-21) Difficulty: 2 of 5
Take, for example, the word INTERPOLATE. It could be broken into 3, INT / ERPOL / ATE, and with these three blocks, you can make the anagrams TIN, POLER and EAT, all English words. Since you broke the initial word in three, your score is 3. Or, you could cut your score to 2, by breaking it into INTERPO / LATE, to form POINTER and TALE. Note that LATE would not be allowed in the latter solution, because each answer word must involve some rearrangement of letters.

If you have trouble anagramming a block, you may add one or more additional letters of your choice, in order to form a word. Each added letter, however, counts as 2 (as a penalty) for your score. If you canīt find any solution for a given word, add 4 points to your score. Contractions, hyphenated words, and capitalized words are not allowed in answers, but plurals and past tense forms of verbs are fine.

Below are 8 words, and I achieve with them a score of 20. Can you match my score or, maybe, achieve a better one?
1. UNSTEADILY        2. INCONSIDERATE     3. ORCHESTRATION     4. SOMNAMBULANCE
5. UNFORTUNATELY     6. MISADAPTATIONS    7. ANTEPENULTIMATE   8. DISENFRANCHISEMENT

See The Solution Submitted by pcbouhid    
Rating: 3.0000 (3 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution computer solution | Comment 4 of 12 |

DECLARE FUNCTION isAnag$ (w$)
DATA  UNSTEADILY, INCONSIDERATE, ORCHESTRATION, SOMNAMBULANCE, UNFORTUNATELY, MISADAPTATIONS, ANTEPENULTIMATE, DISENFRANCHISEMENT
FOR i = 1 TO 8: READ w0$(i): NEXT

CLS

FOR i = 1 TO 8
  w$ = LCASE$(w0$(i))
  PRINT
  PRINT w$
  w1$ = LCASE$(w$)
  anag1$ = isAnag$(w1$)
  IF anag1$ > "" AND anag1$ <> w1$ THEN PRINT anag1$
  flag = 0
  FOR splitaft = 3 TO LEN(w$) - 3
    w1$ = LEFT$(w$, splitaft)
    w2$ = MID$(w$, splitaft + 1)
    anag1$ = isAnag$(w1$)
    anag2$ = isAnag$(w2$)
    IF anag1$ > "" AND anag2$ > "" AND anag1$ <> w1$ AND anag2$ <> w2$ THEN
       PRINT w$; TAB(20); anag1$, anag2$
       flag = 1
    END IF
  NEXT
  IF flag = flag THEN
    FOR splitaft1 = 3 TO LEN(w$) - 6
     FOR splitaft2 = splitaft1 + 3 TO LEN(w$) - 3
      w1$ = LEFT$(w$, splitaft1)
      w2$ = MID$(w$, splitaft1 + 1, splitaft2 - splitaft1)
      w3$ = MID$(w$, splitaft2 + 1)
      anag1$ = isAnag$(w1$)
      anag2$ = isAnag$(w2$)
      anag3$ = isAnag$(w3$)
      IF anag1$ > "" AND anag2$ > "" AND anag3$ > "" AND anag1$ <> w1$ AND anag2$ <> w2$ AND anag3$ <> w3$ THEN
         PRINT w$; TAB(20); anag1$, anag2$, anag3$
         flag = 1
      END IF
     NEXT
    NEXT

  END IF
NEXT

FUNCTION isAnag$ (w$)
  OPEN "\words\words" + LTRIM$(STR$(LEN(w$))) + ".txt" FOR BINARY AS #1
  found = 0
  DO
   w1$ = SPACE$(LEN(w$))
   GET #1, , w1$
   h$ = w1$
   IF EOF(1) THEN EXIT DO
   w2$ = w$
   flag = 1
   FOR i = 1 TO LEN(w2$)
    ix = INSTR(w1$, MID$(w2$, i, 1))
    IF ix THEN
     w1$ = LEFT$(w1$, ix - 1) + MID$(w1$, ix + 1)
    ELSE
     flag = 0: EXIT FOR
    END IF
   NEXT
   IF flag THEN
    found = 1
   END IF
  LOOP UNTIL found
  IF found THEN
   isAnag$ = h$
  ELSE
   isAnag$ = ""
  END IF
  CLOSE 1
END FUNCTION

Lists the following sets. Note that for any given set of letters, such as C, I, N and O it lists only the first found word--in this instance CION, instead of COIN, though the latter is more common:

unsteadily
unsteadily         tunes    daily
unsteadily         unseat   idly
unsteadily         nus      ate           idly
inconsiderate
containerised
inconsiderate      cion     detainers
inconsiderate      conin    readiest
inconsiderate      cion     dins          arete
inconsiderate      conin    dis           arete
orchestration
orchestration      cor      anorthites
orchestration      chore    strontia
orchestration      hectors  aroint
orchestration      cor      eths          aroint
orchestration      cor      earths        into
orchestration      chore    arts          into
orchestration      chores   art           into
somnambulance
somnambulance      mons     bam           cuneal
somnambulance      mons     album         acne
somnambulance      manos    bum           clean
unfortunately
unfortunately      fun      rout          neatly
misadaptations
misadaptations     amids    antipasto
antepenultimate
antepenultimate    pennate  mutilate
disenfranchisement
disenfranchisement finders  machines      net

To pull one set out of these and manually tweak:

unsteadily         tunes    daily                - 2
inconsiderate      coin     detainers - 2
orchestration      chore    strontia - 2
somnambulance      mons     album         acne - 3
unfortunately      fun      tour          neatly - 3
misadaptations     maids    antipasto - 2
antepenultimate    pennate  mutilate - 2
disenfranchisement friends  machines      ten - 3

---
19

But if "containerised" is allowed to score as a 1 for "inconsiderate", then we'd get the score down to 18. 


  Posted by Charlie on 2005-07-21 13:21:23
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (3)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2017 by Animus Pactum Consulting. All rights reserved. Privacy Information