Remove hint.html and index.html
As per discussions on GitHub the index.html and hint.html files should be deleted in favour of README.md files (from any .text/.txt/.markdown/.md files which will be turned into README.md in an upcoming commit).
This commit is contained in:
1 parent
ee8a36310f
commit
77fb0f11a2
143 files changed
-28606
No files matched your search
@@ -1,149 +0,0 @@
|
||||
<!doctype html public "-//W3C//DTD HTML 4.0 Transitional //EN">
|
||||
<html>
|
||||
<head>
|
||||
<meta name="GENERATOR" content="mkd2html 2.2.2">
|
||||
<meta http-equiv="Content-Type"
|
||||
content="text/html; charset=utf-8"> <link rel="stylesheet"
|
||||
type="text/css"
|
||||
href="../hint.css" />
|
||||
<title></title>
|
||||
<title>Best abuse of lámatyávë</title>
|
||||
</head>
|
||||
<body>
|
||||
<CENTER>
|
||||
<IMG SRC="/png/ioccc.png" ALT="IOCCC" height=78 width=267>
|
||||
<P><FONT size="6"><I>The International Obfuscated C Code Contest</I></FONT></P>
|
||||
<div id="bar">
|
||||
<ul>
|
||||
<li><a href="../index.html">About the 27th IOCCC</a></li>
|
||||
<li><a href="../whowon.html">27th IOCCC Winners</a></li>
|
||||
<li><a href="/index.html">IOCCC home</a></li>
|
||||
<li><a href="/winners.html">List of All Winners</a></li>
|
||||
<li><a href="/judges.html">The Judges</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<P><FONT size="6"><B>A 27<sup>th</sup> IOCCC Winner</B></FONT></P>
|
||||
</CENTER>
|
||||
|
||||
|
||||
<h1>Best abuse of lámatyávë</h1>
|
||||
|
||||
<p>Ilya Kurdyukov<br/>
|
||||
<a href="https://github.com/ilyakurdyukov">https://github.com/ilyakurdyukov</a><br/>
|
||||
Twitter: @ilyakurdyukov</p>
|
||||
|
||||
<p>The code for this entry can be found in <a href="prog.c">prog.c</a></p>
|
||||
|
||||
<h2>Judges' comments:</h2>
|
||||
|
||||
<h3>To use:</h3>
|
||||
|
||||
<pre><code>make
|
||||
./prog text_file output_length context_length random_seed
|
||||
</code></pre>
|
||||
|
||||
<h3>Try:</h3>
|
||||
|
||||
<pre><code>./prog Shakespeare.txt 2000 10 1
|
||||
./prog Shakespeare.txt 2000 9 1
|
||||
./prog Shakespeare.txt 2000 8 1
|
||||
# ... Why does it get progressively slower when the context length decreases?
|
||||
|
||||
./prog Eugene_Onegin.txt 2000 10 1
|
||||
# For those not knowing Russian, just to see how the UTF-8 characters are handled
|
||||
</code></pre>
|
||||
|
||||
<p>(<em>Performance depends on the number of same hashes found.</em>
|
||||
<em>Too many identical strings if the context length is small. author</em>)</p>
|
||||
|
||||
<h3>Selected Judges Remarks:</h3>
|
||||
|
||||
<p>We were able to write our own program performing the same trick
|
||||
using the (still non-standard, for some reason) library function <code>memmem</code>,
|
||||
but that way it works too fast regardless of the context length, and it’s much less fun.</p>
|
||||
|
||||
<p>(<em>Wow, amazing! Very fast, but there is a drawback to randomness.</em>
|
||||
<em>If some string only appears after half the input, the first instance</em>
|
||||
<em>of this string will have a 50% chance of occurrence.</em>
|
||||
<em>Example:</em></p>
|
||||
|
||||
<pre><code>echo "00000000000000000000 01 02 02 02 02 02 02" > test.txt
|
||||
./prog test.txt 1000 2 123
|
||||
# more twos in output
|
||||
./rand test.txt 1000 2 123
|
||||
# more ones in output
|
||||
</code></pre>
|
||||
|
||||
<p><em>But this will happen very rarely on real data. author</em>)</p>
|
||||
|
||||
<p>Try using the same random seed and varying the context size.</p>
|
||||
|
||||
<h2>Author’s comments:</h2>
|
||||
|
||||
<h3>Building</h3>
|
||||
|
||||
<pre><code>cc prog.c -o prog
|
||||
</code></pre>
|
||||
|
||||
<h3>Usage</h3>
|
||||
|
||||
<p>This program generates random text from the provided dictionary using a Markov chain, outputs to <code>stdout</code>.</p>
|
||||
|
||||
<pre><code>./prog input.txt 2000 10 12345
|
||||
</code></pre>
|
||||
|
||||
<p>Parameters are:</p>
|
||||
|
||||
<ol>
|
||||
<li><p>dictionary filename
|
||||
Need at least the size of the book, the more the better (1Mb), you can concatenate several books into one file. This should be a text file (not <code>.doc</code>/<code>.pdf</code>). You can feed with books in <code>.fb2</code> format, metadata is filtered. Whitespace characters is also filtered. For languages other than English, it’s better to use ANSI encoding. You can use UTF, but you need to increase chain length (if one ANSI character is encoded as two UTF bytes, then multiply chain length by two).</p></li>
|
||||
<li><p>bytes to generate (limited at 1Mb)</p></li>
|
||||
<li><p>chain length
|
||||
Randomness and performance depend inversely on this parameter and the size of the dictionary. If you feel that bytes are generated too slowly, then you need to increase the length of the chain. This length means that any part of the output of this size in bytes exists somewhere in the dictionary.</p></li>
|
||||
<li><p>random seed</p></li>
|
||||
</ol>
|
||||
|
||||
|
||||
<h3>Example</h3>
|
||||
|
||||
<p>You can try this with the inputs provided with <code>2019/mills</code> from the IOCCC winners.</p>
|
||||
|
||||
<pre><code>$ ./prog shakespeare.txt 2001 10 12345
|
||||
r sons, wives for them, as the hope I had it. This is the way they be not too ra
|
||||
sh a trial of you only. Therefore will not out of door? Nurse: Marry, bachelor,
|
||||
Have other some, he is in Rome: but where is Warwick frowns at his. PRINCE EDWAR
|
||||
D: Where is the light: But I will watch thy waking, what work he makes Amongst y
|
||||
ou? Come, sirs, We shall write to you, fortune and The hazard of much blood. I w
|
||||
ould to heaven, respective lenity, And fire-eyed fury be my convoy in the senten
|
||||
ced; 'tis too horrible, so bloody on the banks If they were created, Would bring
|
||||
them to our presence? FLORIZEL: And those his golden crown, What is six winters
|
||||
? they are but Lewis and Warwick bids you come too late come from the king's fri
|
||||
end, and will do't; for, look you, sir, For still thy true servitor: I will rend
|
||||
an oak And peg thee in his knotty entrails till Thou hast hazel eyes: what eye
|
||||
but such an eye would spy out such a day to-morrow, or next day: He is within th
|
||||
e limit of the like, forsworn to love, Send her a story of more woe Than this is
|
||||
a merry ballad, but a very pretty one. MOPSA: Thou hast amazed me, My name is E
|
||||
lbow: I do lean upon, Now thou art: Thy tears are womanish; thy wild acts denote
|
||||
The unreasonably: come, you must: and there, I then do't to them? VOLUMNIA: Now
|
||||
the red pestilence hangs in our aim, which is yours. What is't your honour, as
|
||||
in war, since then, You have said before: My child is dead; or 'twere not 'long
|
||||
of him; but he, like you, lads; about your ears it is Menenius? Second Officer:
|
||||
Come, come, young wanton and effeminate boy, Takes on the hungry beach Fillip th
|
||||
e stars Shall bitterly begin his wooing that we have in hand are angry And frown
|
||||
ing brow to brow, ourselves, Still your own affections are devised, As blanks, b
|
||||
enevolences, and I thank thee for it. KING HENRY VI: Master lieutenant comes. Ma
|
||||
ster lieutenant comes. Master lieutenant, pray you,-- CORIOLANUS: What's that to
|
||||
him? CHRISTOPHER: At Pembroke, Sir James Blunt, And Rice ap Thomas with a virtu
|
||||
</code></pre>
|
||||
<BR>
|
||||
<HR>
|
||||
<TABLE><TR>
|
||||
<TD><a rel="license" href="https://creativecommons.org/licenses/by-sa/3.0/"><img alt="Creative Commons License" style="border-width:0" src="/png/by-sa-3.0-88x31.png" /></a></TD>
|
||||
<TD><P>© Copyright 1984-2020,
|
||||
<A HREF="/judges.html">Leo Broukhis, Simon Cooper, Landon Curt Noll</A>
|
||||
- All rights reserved<BR>
|
||||
This work is licensed under a <a rel="license" href="https://creativecommons.org/licenses/by-sa/3.0/">Creative Commons Attribution-ShareAlike 3.0 Unported License</a>.</P></TD>
|
||||
<TD> <!--<a href="https://validator.w3.org/check?uri=referer"><img src="https://www.w3.org/Icons/valid-html401" alt="Valid HTML 4.01 Transitional" height="31" width="88"></a>--></TD>
|
||||
</TR></TABLE>
|
||||
</body>
|
||||
</html>
|
||||
Reference in new issue
Block a user