Dealt with out ouf bounds exception