Fixed PR comments. Changed some instances of for (int to for (size_t.