first commit. got most of the functions done