8000 Merge pull request #10 from dbc2201/patch-1 · andro-dev/Java-Coding-Problems@91c3abf · GitHub
[go: up one dir, main page]

Skip to content
10000

Commit 91c3abf

Browse files
Merge pull request PacktPublishing#10 from dbc2201/patch-1
fixed typo in spelling
2 parents 115606b + fb1b669 commit 91c3abf

File tree

1 file changed

+1
-1
lines changed
  • Chapter01/P01_CountDuplicateCharacters/src/modern/challenge

1 file changed

+1
-1
lines changed

Chapter01/P01_CountDuplicateCharacters/src/modern/challenge/Strings.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public static Map<String, Integer> countDuplicateCharactersVCP1(String str) {
5151
// or, like this (this code produce the same result as the commented code above
5252
int cp = str.codePointAt(i);
5353
String ch = String.valueOf(Character.toChars(cp));
54-
if(Character.charCount(cp) == 2) { // 2 means a suroggate pair
54+
if(Character.charCount(cp) == 2) { // 2 means a surrogate pair
5555
i++;
5656
}
5757

0 commit comments

Comments
 (0)
0