some code clean up

Changed from single var to multiple var declaration and fixed some semi-colons for some examples. Will run through others later.