[Python] Split text into sentences by and/or

Discussão em 'Python' iniciado por Stack, Dezembro 1, 2024.

  1. Stack

    Stack Membro Participativo

    Text String:

    text = ‘Turn left and take the door between stairs and elevator. Turn right to the corridor.’


    Desire Output:

    splitted_sentences= [‘turn left’, ‘take the door between stairs and elevator’, ‘turn right to the corridor’]


    How can we split this text into sentences as shown in the splitted_sentences list by Python?

    Continue reading...

Compartilhe esta Página