My C code from my Advanced Programming Class