Ask me anything

RSS Feed
  1. All responses Most smiled responses
    1. kenhuffman
    2. kenhuffman
    3. kenhuffman
    4. kenhuffman
    5. kenhuffman
    6. kenhuffman
    7. kenhuffman

      When it is warm, I like to bicycle. When it is cold, I watch the weather forecast hoping for warmth.

    8. kenhuffman

      In the unlikely event that I would ever get a tattoo, it would be a small, stylized bicycle image above my ankle. Not that I've given it much thought. :-)

    9. kenhuffman
    10. kenhuffman

      The Huffman algorithm is a way to encode fixed length objects (often bytes) of an input into variable length bits. This allows content to be compressed into smaller files. It is used within MP3 and JPG files. I describe the algorithm here: http://www.huffmancoding.com/my-family/my-uncle/huffman-algorithm

    11. kenhuffman

      In Huffman coding you need to count the occurrences of the input. Use a Map with the keys being the letters and the values being that letter's frequency. For each letter read in, do a get() to find the previous count, increment it and then put() it back. If it is the first time the letter has been encountered, the get() will return null, so just do a put(letter, 1).

      (Didn't know Formspring would be a programming help desk.)

    12. kenhuffman
      kenhuffman posted a new profile photo

friends

Advertisement

Who kenhuffman is following

  • Emily Ash
  • Formspring
  • Renee Olstead
  • FunnyOrDie
See all »