Salve ragazzi ho questo errore:

java.lang.ArrayIndexOutOfBoundsException: 11 >= 11

quando devo andare ad eliminare tutte le righe da una tabella:

il codice per l'eliminazione è:

codice:
	int numerorighe=jTableRicerca.getRowCount();
							System.out.println(numerorighe);
							if(numerorighe>0){
								int j=0;
							while(numerorighe>j){
								System.out.println("righe "+numerorighe);
								System.out.println("j: "+j);
							model.removeRow(j);
							j++;
							}
							}
ho fatto stampare le righe e la variabile j:

righe 22
j: 0
righe 22
j: 1
righe 22
j: 2
righe 22
j: 3
righe 22
j: 4
righe 22
j: 5
righe 22
j: 6
righe 22
j: 7
righe 22
j: 8
righe 22
j: 9
righe 22
j: 10
righe 22
j: 11

e non capisco perchè mi va in errore