Created
August 31, 2011 18:54
-
-
Save capotej/1184376 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Copyright (c) 1983 University of Maryland Computer Science Department */ | |
/* Ultra-hot screen management package | |
Original code copyright (c) James Gosling, January 1980 */ | |
/* Severe munging and destruction by Chris Torek, 1982,1983 */ | |
/**************************************************************** | |
/-------------\ | |
/ \ | |
/ \ | |
/ \ | |
| XXXX XXXX | | |
| XXXX XXXX | | |
| XXX XXX | | |
\ X / | |
--\ XXX /-- | |
| | XXX | | | |
| | | | | |
| I I I I I I I | | |
| I I I I I I | | |
\ / | |
-- -- | |
\-------/ | |
XXX XXX | |
XXXXX XXXXX | |
XXXXXXXXX XXXXXXXXXX | |
XXXXX XXXXX | |
XXXXXXX | |
XXXXX XXXXX | |
XXXXXXXXX XXXXXXXXXX | |
XXXXX XXXXX | |
XXX XXX | |
************** | |
* BEWARE!! * | |
************** | |
All ye who enter here: | |
Most of the code in this module | |
is twisted beyond belief! | |
Tread carefully. | |
If you think you understand it, | |
You Don't, | |
So Look Again. | |
****************************************************************/ | |
/* 1 2 3 4 .... Each Mij represents the minumum cost of | |
+---+---+---+---+----- rearranging the first i lines to map onto | |
1 | | | | | the first j lines (the j direction | |
+---+---+---+---+----- represents the desired contents of a line, | |
2 | | \| ^ | | i the current contents). The algorithm | |
+---+---\-|-+---+----- used is a dynamic programming one, where | |
3 | | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment