Added comments and working on debugging- test is currently getting stuck inside of calcTargets