deleting old algorithm pseudocode