Skip to content

Instantly share code, notes, and snippets.

View wavescholar's full-sized avatar
🎯
Focusing

Bruce Campbell wavescholar

🎯
Focusing
  • These are projects that I have developed out of academic interest or as part of various consulting roles.
  • Columbus, Ohio
View GitHub Profile
@wavescholar
wavescholar / gist:10152479
Last active August 29, 2015 13:58
Stream Cipher Code - Experimental
#include <string>
#include <iostream>
#include <map>
#include <vector>
#include <cctype>
int to_int(int c) {
if (! isxdigit(c)) return -1; // error: non-hexadecimal digit found
if (isdigit(c)) return c - '0';
if (isupper(c)) c = tolower(c);