Add more comments, remove unneeded array declaration