"The Knapsack Problem" is, barely, my third work of interactive
fiction. I say "barely" because, while there is a plot, a room, and
several items, it's really just a standard algorithms problem
transposed to the IF medium. Consider this my tribute to all those
implementations of Towers of Hanoi in the middle of otherwise
respectable games.

The game is written in straight Inform; no library needed. The phrases
which are shuffled to form the names of the treasures are found in
adjectives.txt, nouns.txt, and ofs.txt. makeitems.py is a Python
script which reads those three files and writes some Inform array
definitions to items.inf. The current items.inf is provided for the
Python impaired.

I've made some tweaks to the generation of the weights and values in
hopes of making the puzzle harder, but your results may vary. I
personally find it difficult to get the optimal solution, but Cedric
Knight, my perennial beta tester, claims it's easy.

The program uses brute force to find the optimal solution, trying all
1024 combinations of treasures. I didn't do a dynamic programming
solution because I don't trust Inform arrays. And also, I'm lazy.

Leonard Richardson
leonardr@segfault.org
http://www.crummy.com/

CHANGELOG:
----------
Release 1: Original LoTechComp release.

Release 2: Changed Python script to generate simple arrays instead of
complicated selection code.

Release 3: Fixed stupid, stupid bug, complained about by Adam Cadre in
his review, by which it would claim you hadn't gotten the optimal
solution even though you had.
