star_out¶
Return a version of the given string, where for every star () in the string the star and the chars immediately to its left and right are gone. So “abcd” yields “ad” and “ab**cd” also yields “ad”.
This exercise was taken from codingbat.com and has been adapted for the Python language. There are many great programming exercises there, but the majority are created for Java.