19-Section-Handout

19-Section-Handout - CS106X Autumn 2009 Handout 19 Section...

This preview shows pages 1–3. Sign up to view the full content.

CS106X Handout 19 Autumn 2009 October 19 th , 2009 Section Handout Problem 1: Creating Word Wreck Tangles Several summers ago, I discovered a dashboard element for my Google Home Page that served up a new type of puzzle every week. One of these puzzles was the Word Wreck Tangle, and it looked like this: The goal of the game is to slide each of the 18 letters around the perimeter into the board in such a way that you’re left with a grid of nine overlapping words—four across and five down. Here’s the solution: Here’s what I want to know! How do people find these boards in the first place? Are some people so inventive that they can just see that scabs stacked on top of tacit on top of array and geese just so happens to give you five four-letter words as well? Is it really that obvious?

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
2 Perhaps to some, but it needn’t be, because we have recursive backtracking and the programmatic ability to generate a word wreck tangle, see what it gives us, and then pretend we didn’t use a computer but just found it own our own. Your job here is actually a pretty tough one: write a recursive procedure that takes an empty Grid<char> (actually, it’s a Grid<char> of space characters), and populates it with an assortment of letters that just happens to be four words across and fives words down. Here’s the prototype:
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 03/07/2010 for the course CS 201 taught by Professor Selimaksoy during the Spring '09 term at Bilkent University.

Page1 / 4

19-Section-Handout - CS106X Autumn 2009 Handout 19 Section...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online