Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Shitty poetry [C]

Name: Anonymous 2011-08-07 4:12

I wrote this shitty program a-la http://robohash.org/
Enjoy your poetry
cc poemhash.c -lcrypto
./a.out sicp
river was like pumpkin-eater on the pines on the hem locks
midnight of their forgotten with chamber door was like wind
woodlands with midnight of their comedy of their tree
people with comedy of their forest of their stars



#include <stdio.h>
#include <string.h>
#include <openssl/md5.h>

const char *words[64] =
  { "sheen", "spears", "stars", "sea", "death", "pumpkin-eater", "boat", "river",
    "silver", "pines", "forest", "hem locks", "cradle", "coat", "music", "spring",
    "ivy-leaves", "green", "fresh", "deserts", "tears", "flow", "midnight", "weak",
    "volume", "forgotten", "chamber door", "snow", "woodlands", "fairy", "dream", "tree",
    "shore", "battle", "tribe", "people", "palace", "love", "highway", "loot",
    "comedy", "bones", "labour", "home", "wind", "change", "bird", "midnight",
    "life", "belongings", "tears", "eyes", "flame", "heart", "chastity", "magic",
    "flea", "marriage", "paradox", "distance", "sun", "theory", "automation", "history"
  };

const char *connectives[4] = { "was like", "on the", "of their", "with" };

void hashtopoem(const char *hash, FILE *out)
/* Convert hash to poem and write to out */
{
  const unsigned char *p = hash;
  int i, j, k, t;
  for(k = 0; k < 16; k++) {
    i = p[k] >> 2;
    j = p[k] & 3;
    t = (k + 1) % 4;
    fprintf(out, "%s %s%c", words[i], t ? connectives[j] : "", t ? ' ' : '\n');
  }
}

int main(int argc, char **argv) {
  char hash[16];
  if(argc == 2) {
    MD5(argv[1], strlen(argv[1]), hash);
    hashtopoem(hash, stdout);
  }
  return 0;
}

Name: Anonymous 2011-08-08 12:40

>>8
God says
bones was like fairy on the tree on the fairy
boat on the history with music with fresh
paradox on the hem locks of their palace was like midnight
snow with sea of their fairy on the fresh
magic on the pines of their paradox of their tribe
forest with belongings was like people on the boat
ivy-leaves was like music was like bird on the loot
deserts with magic with volume on the forest
home of their palace of their spears with ivy-leaves
marriage with woodlands of their life was like flea
cradle of their woodlands on the history on the forgotten
boat was like spring was like cradle was like palace

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List