We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9979643 commit 517b25eCopy full SHA for 517b25e
src/main/java/com/fishercoder/solutions/_249.java
@@ -17,9 +17,9 @@ public List<List<String>> groupStrings(String[] strings) {
17
for (String word : strings) {
18
//calculate the representative/key that's unique for the entire group
19
//i.e. if the two string belong to the same group, after shifting n times, they all will end up having the same key
20
- // abc -> 2021
21
- // xyz -> 2021
22
- // acef -> 212324
+ // abc -> "2021"
+ // xyz -> "2021"
+ // acef -> "212324"
23
String key = "";
24
int offset = word.charAt(0) - 'a';
25
for (int i = 1; i < word.length(); i++) {
0 commit comments