Cody Bable

Generation

generate functionWed, 19 Apr 2023

remove punctuations from a sentence and split the sentence into a list

def split_sentence(sentence): sentence = sentence.replace(',', '').replace('.', '').replace('?', '').replace('!', '') return sentence.split(' ') split_sentence('Hello, world.')

Want to kickstart your project?Use the new AI Studio to create your code