PYTHON QUESTION! A sentence will be any sequence of words that is terminated by a full stop (and including the full stop

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899604
Joined: Mon Aug 02, 2021 8:13 am

PYTHON QUESTION! A sentence will be any sequence of words that is terminated by a full stop (and including the full stop

Post by answerhappygod »

PYTHON QUESTION!
A sentence will be any sequence of words that is terminated
by a full stop (and including the full stop itself). Test Case
2 should illustrate this.
Write a function sentence_segmentation(document) that
takes an input parameter document (type string)
and returns a list of sentences from the given
document. If no sentences could be segmented (think about the
cases), then it simply returns an empty list.
NB: You are guaranteed that a document will not begin with the
full stop character.
For example:
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply