Skip to content

Commit 265d52f

Browse files
Correct inconsistent capitalisation of "valuesAtIndex"
1 parent 344de31 commit 265d52f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

data/part-12/2-arraylist-and-hashtable.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -769,9 +769,9 @@ public V get(K key) {
769769

770770
List<Pair<K, V>> valuesAtIndex = this.values[hashValue];
771771

772-
for (int i = 0; i < valuesAtINdex.size(); i++) {
772+
for (int i = 0; i < valuesAtIndex.size(); i++) {
773773
if (valuesAtIndex.value(i).getKey().equals(key)) {
774-
return valuesAtindex.value(i).getValue();
774+
return valuesAtIndex.value(i).getValue();
775775
}
776776
}
777777

@@ -843,7 +843,7 @@ public void add(K key, V value) {
843843
values[hashValue] = new List<>();
844844
}
845845

846-
List<Pari<K, V>> valuesAtindex = values[hashValue];
846+
List<Pari<K, V>> valuesAtIndex = values[hashValue];
847847

848848
int index = -1;
849849
for (int i = 0; i < valuesAtIndex.size(); i++) {
@@ -937,7 +937,7 @@ public void add(K key, V value) {
937937
valuesAtIndex.add(new Pair<>(key, value));
938938
this.firstFreeIndex++;
939939
} else {
940-
valuesAtindex.value(index).setValue(value);
940+
valuesAtIndex.value(index).setValue(value);
941941
}
942942
}
943943
```

0 commit comments

Comments
 (0)