     "outputs": [],
     "source": [
      "def unique_chars_alt(string):\n",
      "    for char in string:\n",
      "        if string.count(char) > 1:\n",
      "            return False\n",
      "    return True"
     ]
    },
    {
 
</s> remove     "def unique_chars_alt2(string):\n",
    "    return len(set(string)) == len(string)"
 </s> add     "def unique_chars_alt(string):\n",
    "    for char in string:\n",
    "        if string.count(char) > 1:\n",
    "            return False\n",
    "    return True" </s> remove     "    chars_set = set()\n",
    "    for char in string:\n",
    "        if char in chars_set:\n",
    "            return False\n",
    "        else:\n",
    "            chars_set.add(char)\n",
    "    return True\n",
 </s> add     "    return len(set(string)) == len(string)\n", </s> remove     "## Pythonic Solution(s)"
 </s> add     "## Algorithm 3: In-Place\n",
    "\n",
    "Since we cannot use additional data structures, this will eliminate the fast lookup O(1) time provided by our hash map.\n",
    "* Scan each character\n",
    "* For each character:\n",
    "    * Scan all [other] characters in the array\n",
    "        * Exluding the current character from the scan is rather tricky in Python and results in a non-Pythonic solution\n",
    "        * If there is a match, return False\n",
    "* Return True\n",
    "\n",
    "Algorithm Complexity:\n",
    "* Time: O(n^2)\n",
    "* Space: In-place"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Code: In-Place"
    "        if char in chars_set:\n",
     "outputs": [],
     "source": [
      "def unique_chars_alt(string):\n",
      "    for char in string:\n",
    "        if char in chars_set:\n",
      "            return False\n",
      "    return True"
     ]
    },
    {
keep keep keep keep replace keep keep keep keep keep
 Reworked algorithm descriptions.  Added notebook index.  Minor cleanup. 
arrays-strings/unique_chars.ipynb