Interview Query

Stop Words Filter

7
Have you seen this question before?

Given a list of stop words, write a function stopwords_stripped that takes a string and returns a string stripped of the stop words.

Example:

stopwords = [
    'I', 
    'as', 
    'to', 
    'you', 
    'your', 
    'but', 
    'be', 
    'a',
]

paragraph = 'I want to figure out how I can be a better data scientist'

Output:

def stopwords_stripped(paragraph,stopwords)
     return(stripped_paragraph) ->

stripped_paragraph = 'want figure out how can better data scientist'
Next question: Attribution Rules
Python 3.9.6
Loading editor