Just use the end parameter in print function. (I assumed that you are using python 3.x, with print being a function)
def translate(string): vowels=['a','e','i','o','u'] for letter in string: if letter in vowels: print(letter, end=' 'end='') else: print(letter+'o'+letter, end=' 'end='') print(translate('this is fun'))