Changed cbegin to begin and cend to end.