my_string = "Hello, World! This is a test string." new_string = my_string.replace(',', '') new_string = new_string.replace('!', '') print(new_string)