mirror of
https://github.com/donnemartin/interactive-coding-challenges
synced 2026-01-02 23:48:02 +00:00
Add assumption to str diff challenge to match the suggested solution (#178)
This commit is contained in:
committed by
Donne Martin
parent
2c6982f154
commit
fcd4e52e91
@@ -34,6 +34,7 @@
|
||||
"source": [
|
||||
"## Constraints\n",
|
||||
"\n",
|
||||
"* Assume two strings str1, str2, where str2 contains the same set of characters in str1 with one additional character.\n",
|
||||
"* Can we assume the strings are ASCII?\n",
|
||||
" * Yes\n",
|
||||
"* Is case important?\n",
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
"\n",
|
||||
"Complexity:\n",
|
||||
"* Time: O(m+n), where m and n are the lengths of s, t\n",
|
||||
"* Space: O(1), for the dict, where h is the unique chars in s"
|
||||
"* Space: O(1)"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user