added comments attributing code