restructuring, commenting desired functionality