fixed broken comments & variable names
improved documentation & legibility of snippets file