subject

Build a grammar checker function gram_check that takes as an input, sentences of the form [Pronoun] [present tense verb] [object] ex., He plays basketball and ensures that there is a subject-verb agreement; i. e. it distinguishes between He plays basketball and *You plays basketball. Important notes: The subject can be any of I, you, he, she, it, they. The verb can be any regular verb. The object can be any object. Your program must print "Grammatical" if the sentence is grammatical and "Ungrammatical" if the sentence is ungrammatical. Some structure within gram_check has been provided below, but you may change it if you wish. However, do not change the name of the function. import re def gram check(s): #Put your code here if #Put your code here return "Grammatical" else: return Ungrammatical" gram check("she play basketball")Out [11]: 'Ungrammatical'

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 17:00
Your company has 1,500 desktop computers running windows 7. you want to upgrade them to windows 10. which type of microsoft license would be best suited in this situation?
Answers: 3
question
Computers and Technology, 22.06.2019 17:30
The forerunner to cell phones, pdas, and smartphones was
Answers: 1
question
Computers and Technology, 23.06.2019 21:20
In microsoft word, when you highlight existing text you want to replace, you're in              a.  advanced mode.    b.  automatic mode.    c.  basic mode.    d.  typeover mode
Answers: 1
question
Computers and Technology, 24.06.2019 15:30
If you want to delete an entire word at a time, which key should you press along with the backspace or delete key?
Answers: 1
You know the right answer?
Build a grammar checker function gram_check that takes as an input, sentences of the form [Pronoun]...
Questions
question
Mathematics, 03.03.2021 01:40
question
Mathematics, 03.03.2021 01:40
question
Mathematics, 03.03.2021 01:40
Questions on the website: 13722361