      "    printf(\"%s \\n\", test1);\n",
      "    return 0;\n",
      "}"
     ]
    },
    {
     "cell_type": "markdown",
     "metadata": {},
     "source": [
      "## Pythonic-Code\n",
      "\n",
      "This question has an artificial constraint that prevented the use of the slice operator and the reversed method.  For completeness, the solutions for these are provided below."
     ]
    },
    {
     "cell_type": "code",
     "execution_count": 7,
     "metadata": {
      "collapsed": false
     },
     "outputs": [],
     "source": [
      "def reverse_string_alt(string):\n",
      "    if string is None:\n",
      "        return None\n",
      "    return string[::-1]\n",
      "\n",
      "def reverse_string_alt2(string):\n",
      "    if string is None:\n",
      "        return None    \n",
      "    return ''.join(reversed(string))\n",
      "\n",
      "run_tests(reverse_string_alt)\n",
      "run_tests(reverse_string_alt2)"
     ]
    }
   ],
   "metadata": {
    "kernelspec": {
     "display_name": "Python 2",
 
</s> remove    "execution_count": 4,
 </s> add    "execution_count": null, </s> remove    "execution_count": 3,
 </s> add    "execution_count": null, </s> remove     "* [C Code]()\n",
    "* [Pythonic-Code](#Pythonic-Code)"
 </s> add     "* [C Code]()"
      "    printf(\"%s \\n\", test1);\n",
      "    return 0;\n",
      "}"
     ]































    }
   ],
   "metadata": {
    "kernelspec": {
     "display_name": "Python 2",
keep keep keep keep replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace keep keep keep keep keep
 Moved pythonic solution after the initial python solution and prior to the C solution. 
arrays-strings/reverse_string.ipynb