Ad
  • Custom User Avatar

    You can simnplify your code by using list comprehension for creating 'phrase_list' and 'new_indexes'. You could also use enumerate(indexes) to loop through the indexes and insert the word at a specified location.

  • Custom User Avatar

    I'm not sure it's the only problem with your code, but it returns False if both arrays are empty (the description requires to return False if they are None, but not if they are empty).