first attempt at adding psuedo-code