      "def main():\n",
      "    test = TestSelectionSort()\n",
      "    test.test_selection_sort(selection_sort)\n",
      "    try:\n",
      "        test.test_selection_sort(selection_sort_recursive)\n",
      "        test.test_selection_sort(selection_sort_iterative_alt)\n",
      "    except NameError:\n",
      "        # Alternate solutions are only defined\n",
      "        # in the solutions file\n",
      "        pass\n",
      "\n",
 
</s> remove     "        test.test_selection_sort(selection_sort_recursive)\n",
    "        test.test_selection_sort(selection_sort_iterative_alt)\n",
 </s> add     "        test.test_selection_sort(selection_sort.sort_recursive)\n",
    "        test.test_selection_sort(selection_sort.sor_iterative_alt)\n", </s> remove     "    test.test_selection_sort(selection_sort)\n",
 </s> add     "    selection_sort = SelectionSort()\n",
    "    test.test_selection_sort(selection_sort.sort)\n", </s> remove     "    test.test_selection_sort(selection_sort)\n",
 </s> add     "    selection_sort = SelectionSort()\n",
    "    test.test_selection_sort(selection_sort.sort)\n", </s> remove         test.test_selection_sort(selection_sort_recursive)
        test.test_selection_sort(selection_sort_iterative_alt)
 </s> add         test.test_selection_sort(selection_sort.sort_recursive)
        test.test_selection_sort(selection_sort.sor_iterative_alt) </s> remove     "def selection_sort(data):\n",
    "    if data is None or len(data) < 2:\n",
    "        return\n",
    "    for i in range(len(data)-1):\n",
    "        min_index = i\n",
    "        for j in range(i + 1, len(data)):\n",
    "            if data[j] < data[min_index]:\n",
    "                min_index = j\n",
    "        data[i], data[min_index] = data[min_index], data[i]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Below are alternate solutions with helper functions:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "def find_min_index(data, start):\n",
    "    # Raises an exception if: \n",
    "    # -data is None\n",
    "    # -start >= len(data) - 1\n",
    "    min_index = start\n",
    "    for i in range(start + 1, len(data)):\n",
    "        if data[i] < data[min_index]:\n",
    "            min_index = i\n",
    "    return min_index\n",
 </s> add     "class SelectionSort(object):\n",
    "        test.test_selection_sort(selection_sort.sort_recursive)\n",
    "        test.test_selection_sort(selection_sort.sor_iterative_alt)\n",
      "def main():\n",
      "    test = TestSelectionSort()\n",
      "    test.test_selection_sort(selection_sort)\n",
      "    try:\n",
    "        test.test_selection_sort(selection_sort.sort_recursive)\n",
    "        test.test_selection_sort(selection_sort.sor_iterative_alt)\n",
    "        test.test_selection_sort(selection_sort.sort_recursive)\n",
    "        test.test_selection_sort(selection_sort.sor_iterative_alt)\n",
      "    except NameError:\n",
      "        # Alternate solutions are only defined\n",
      "        # in the solutions file\n",
      "        pass\n",
      "\n",
keep keep keep keep replace replace keep keep keep keep keep
 Update selection sort challenge (#131)

Update constraints, test cases, code, and tests. 
sorting_searching/selection_sort/selection_sort_challenge.ipynb