Closed ejini6969 closed 4 weeks ago
LeetCode Support commented: Hello,
Your reported issue has been relayed to our team for thorough investigation. We appreciate your patience as we work to address and resolve this matter. We will reach out to you when we have updates regarding the issue.
If you have any further questions or concerns in the meantime, please feel free to let us know.
Best regards, LeetCode Support Team
Epiphania_Ekenimoh commented: Thank you for your time.
Your feedback has been used to enhance the problem. As a token of our appreciation, your LeetCode account has been credited with 100 LeetCoins.
If you have any more questions or additional feedback, please don't hesitate to let us know. Your continued support is invaluable to us!
Best regards, The LeetCode Team
"* For approach 3, following should be updated too (add quotes around s1map
and remove extra parenthesis)
Same applies to approach 4 below:
Approach 6 -> we do not check matches
function within inner loop, so the extra 26
should be changed to 1
which is equivalent to O(l1 + (l2 - l1))
.
Approach 6 -> algorithm explanation should be updated to s1arr
and s2arr
too.
Epiphania_Ekenimoh commented: Hello,
Your reported issue has been relayed to our team for thorough investigation. We appreciate your patience as we work to address and resolve this matter. We will reach out to you when we have updates regarding the issue.
If you have any further questions or concerns in the meantime, please feel free to let us know.
Best regards, LeetCode Support Team
The time complexity for Approach 6 is not $O(l_1β+26\times (l2β β l{1}β))$ but $O(l_1 + l_2 + 26)$, although it simplifies to $O(l_2)$ anyway.
Epiphania_Ekenimoh commented: Hello there,
The issue you reported has been resolved. Please feel free to verify and retry.
We apologize for any inconvenience this may have caused and appreciate your patience while we worked to resolve the issue. If you have any further questions or concerns, please do not hesitate to contact us.
Thank you, LeetCode Support Team
The last 2 suggestion for the latest post above are not implemented, please fix.
Epiphania_Ekenimoh commented: Hello,
Your reported issue has been relayed to our team for thorough investigation. We appreciate your patience as we work to address and resolve this matter. We will reach out to you when we have updates regarding the issue.
If you have any further questions or concerns in the meantime, please feel free to let us know.
Best regards, LeetCode Support Team
Epiphania_Ekenimoh commented: Hello there,
The issue you reported has been resolved. Please feel free to verify and retry.
We apologize for any inconvenience this may have caused and appreciate your patience while we worked to resolve the issue. If you have any further questions or concerns, please do not hesitate to contact us.
Best regards, LeetCode Support Team
LeetCode Username
https://leetcode.com/u/ejini6969/
Problem Number, Title, and Link
567. Permutation in String
Bug Category
Editorial
Bug Description
Approach 1 -> intro quote
should be
Approach 1 -> Time complexity has no explanation, should be something equivalent like below:
Approach 2 -> Algorithm
Approach 2 -> Time Complexity -> Lack of explanation and should only display the dominating term. Should be re-worded to something equivalent like below.
Approach 2 -> Space complexity -> Lack of explicit mention of sorting in-place also requires additional space. Something equivalent like below should be incorporated with original explanation.
Approach 3 -> Wrong + Lack of Explanation for Time Complexity
should be
O(l1 + (26 + l1) (l2 - l1))
since the process of storing the hashmap and looping of the inner-loop occurs at the same level, hence it should be addition instead of multiplication.Also, Explanation on how to derive each individual's operations' complexity is required.
Approach 3 -> Wrong space complexity
The space complexity is not
O(1)
because it will change based on the input size given byl1
andl2
. Within the inner-loop, we are doingO(26 * (l2 - l1))
in which the size of our space used to store each instance of hashmap isO(26)
at worse, but we need to storel2 - l1
instances of hashmap at worse too.Approach 4 -> Time Complexity -> Applies to the point same as approach 3
Approach 4 -> Space Complexity -> Applies to the point same as approach 3
Approach 5 -> Misleading term
hashmap
as the implementation uses a 26-length fixed-size array.Approach 5 -> Lack of explanation on T.C and S.C
Approach 6 -> Missing explanations too
Approach 4 - 6 implementation should change variable name from
s1map
,s2map
respectively tos1arr
,s2arr
since hashmap is not equivalent to a 26-length fixed-size array.Language Used for Code
None
Code used for Submit/Run operation
No response
Expected behavior
Editorial should provide concise and latest info to user.
Screenshots
No response
Additional context
No response