updating: added algorithm class implementation and seperate files for each algorithm (with inheritance of algorithm class)