      "\n",
      "* None -> None\n",
      "* '' -> ''\n",
      "* 'AABBCC' -> 'AABBCC'\n",
      "* 'AAABCCDDDD' -> 'A3B1C2D4'"
     ]
    },
    {
     "cell_type": "markdown",
     "metadata": {},
 
</s> remove     "## Problem: Compress a string such that 'AAABCCDDDD' becomes 'A3B1C2D4'.  Only compress the string if it saves space.\n",
 </s> add     "## Problem: Compress a string such that 'AAABCCDDDD' becomes 'A3BCCD4'.  Only compress the string if it saves space.\n", </s> remove     "            * Append last_char to compressed_string\n",
    "            * append count to compressed_string\n",
    "            * count = 1\n",
    "            * last_char = char\n",
 </s> add     "            * If the count is more than 2\n",
    "                * Append last_char to compressed_string\n",
    "                * append count to compressed_string\n",
    "                * count = 1\n",
    "                * last_char = char\n",
    "            * If count is 1\n",
    "                * Append last_char to compressed_string\n",
    "                * count = 1\n",
    "                * last_char = char\n",
    "            * If count is 2\n",
    "                * Append last_char to compressed_string\n",
    "                * Append last_char to compressed_string once more\n",
    "                * count = 1\n",
    "                * last_char = char\n", </s> remove    "execution_count": 3,
 </s> add    "execution_count": 16, </s> remove    "execution_count": 2,
 </s> add    "execution_count": 15,
    "* 'AAABCCDDDD' -> 'A3BCCD4'"
      "\n",
      "* None -> None\n",
      "* '' -> ''\n",
      "* 'AABBCC' -> 'AABBCC'\n",
    "* 'AAABCCDDDD' -> 'A3BCCD4'"
     ]
    },
    {
     "cell_type": "markdown",
     "metadata": {},
keep keep keep keep replace keep keep keep keep keep
 Improved compression by only appending count if the count is more than 2 
arrays_strings/compress/compress_solution.ipynb