     "metadata": {},
     "source": [
      "## Test Cases\n",
      "\n",
      "* Empty input -> []\n",
      "* One element -> [element]\n",
      "* Two or more elements"
     ]
 
</s> remove     "* Space: O(n), n extra space, n recursion depth, generally not stable"
 </s> add     "* Space: O(n+m), n = number of elements, m = recursion depth\n",
    "\n",
    "Most implementations are not stable." </s> remove   {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Pythonic-Code\n",
    "\n",
    "The following code from [Stack Overflow](http://stackoverflow.com/questions/18262306/quick-sort-with-python) is very concise, although it might be a little difficult to read:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "def quick_sort_alt(arr):\n",
    "    if len(arr) <= 1:\n",
    "        return arr\n",
    "    else:\n",
    "        return quick_sort_alt([x for x in arr[1:] if x < arr[0]]) + [arr[0]] + quick_sort_alt([x for x in arr[1:] if x >= arr[0]])"
   ]
  },
 </s> add  </s> remove       "Empty input\n",
      "One element\n",
      "Two or more elements\n",
      "Success: test_quick_sort\n",
      "\n",
 </s> add       "None input\n", </s> remove     "    if len(data) < 2:\n",
 </s> add     "    if data is None or len(data) < 2:\n",
    "* None -> None\n",
     "metadata": {},
     "source": [
      "## Test Cases\n",
      "\n",
    "* None -> None\n",
      "* Empty input -> []\n",
      "* One element -> [element]\n",
      "* Two or more elements"
     ]
keep keep keep add keep keep keep keep
 Polish quicksort challenge and solution

Add None input test case.  Remove difficult to read 'Pythonic' solution.  Update space complexity discussion. 
sorting_searching/quick_sort/quick_sort_challenge.ipynb