Alan's child can be annoying at times.

When Alan comes home and tells his kid what he has accomplished today, his kid never believes him. 

Be that kid.

Your function 'AlanAnnoyingKid' takes as input a sentence spoken by Alan (a string). The sentence contains the following structure:

    "Today I " + [action_verb] + [object] + "."

    (e.g.: "Today I played football.")


Your function will return Alan's kid response, which is another sentence with the following structure:

    "I don't think you " + [action_performed_by_alan] + " today, I think you " + ["did" OR "didn't"] + [verb_of _action_in_present_tense] + [" it!" OR " at all!"]

    (e.g.:"I don't think you played football today, I think you didn't play at all!")


Note the different structure depending on the presence of a negation in Alan's first sentence (e.g., whether Alan says "I dind't play football", or "I played football").

! Also note: Alan's kid is young and only uses simple, regular verbs that use a simple "ed" to make past tense. 
There are random test cases.

Some more examples:

    input  = "Today I played football."
    output = "I don't think you played football today, I think you didn't play at all!"
    
    input  = "Today I didn't attempt to hardcode this Kata."
    output = "I don't think you didn't attempt to hardcode this Kata today, I think you did attempt it!"
          
    input  = "Today I didn't play football."
    output = "I don't think you didn't play football today, I think you did play it!"
          
    input  = "Today I cleaned the kitchen."
    output = "I don't think you cleaned the kitchen today, I think you didn't clean at all!"

Difficulty: EASY
Starter code: def alan_annoying_kid(s):
	

Solutions:
OUTPUT = "I don't think you {} today, I think you {} {} {}!".format

def alan_annoying_kid(phrase):
	words = phrase.split()
	action = ' '.join(words[2:]).rstrip('.')
	if "didn't" in phrase:
		return OUTPUT(action, 'did', words[3], 'it')
	return OUTPUT(action, "didn't", words[2][:-2], 'at all')


def alan_annoying_kid(sentence):
	action = sentence.split(None, 2)[-1].rstrip('.')
	if "didn't" in sentence:
		(verb, did, it) = (action.split(None, 2)[1], 'did', 'it')
	else:
		(verb, did, it) = (action.split(None, 1)[0][:-2], "didn't", 'at all')
	return "I don't think you {} today, I think you {} {} {}!".format(action, did, verb, it)


import re

def alan_annoying_kid(s):
	action = s[8:-1]
	d = ['did', "didn't"]["didn't" not in action]
	present = re.sub('ed$', '', re.search('^\\w+', action.replace("didn't ", '')).group())
	return "I don't think you " + action + ' today, I think you ' + d + ' ' + present + [' it!', ' at all!'][d == "didn't"]


def alan_annoying_kid(stg):
	s1 = stg.replace('Today I ', '')[:-1]
	s3 = s1.replace("didn't ", '').split()[0]
	(s2, s3, s4) = ('did', s3, 'it') if "n't" in s1 else ("didn't", s3[:-2], 'at all')
	return f"I don't think you {s1} today, I think you {s2} {s3} {s4}!"


def alan_annoying_kid(s):
	lst = s.split()
	isNegative = lst[2] == "didn't"
	verb = lst[2 + isNegative]
	cplt = ' '.join(lst[3 + isNegative:])
	return "I don't think you didn't {} {} today, I think you did {} it!".format(verb, cplt[:-1], verb) if isNegative else "I don't think you {} {} today, I think you didn't {} at all!".format(verb, cplt[:-1], verb[:-2])


def alan_annoying_kid(sentence):
	if "didn't" in sentence:
		(verb, subject) = sentence[15:-1].split(' ', 1)
		return "I don't think you didn't %s %s today, I think you did %s it!" % (verb, subject, verb)
	(verb, subject) = sentence[8:-1].split(' ', 1)
	return "I don't think you %s %s today, I think you didn't %s at all!" % (verb, subject, verb[:-2])


def alan_annoying_kid(stg):
	response = "I don't think you {0} today, I think you {1} {2} {3}!".format
	what = stg.replace('Today I ', '')[:-1]
	made = what.replace("didn't ", '').split()[0]
	filler = (what, 'did', made, 'it') if "didn't" in what else (what, "didn't", made[:-2], 'at all')
	return response(*filler)


def alan_annoying_kid(s):
	a = s[:-1].split()
	b = f'did {a[3]} it' if a[2] == "didn't" else f"didn't {a[2][:-2]} at all"
	return f"I don't think you {' '.join(a[2:])} today, I think you {b}!"


def alan_annoying_kid(s):
	negative = False
	a = s.split()
	a[-1] = a[-1][:-1]
	if a[2] == "didn't":
		negative = True
	if not negative:
		return "I don't think you " + ' '.join(a[2:]) + " today, I think you didn't " + str(a[2][:-2]) + ' at all!'
	return "I don't think you didn't " + ' '.join(a[3:]) + ' today, I think you did ' + str(a[3]) + ' it!'


import re

def alan_annoying_kid(sentence):
	if "didn't" in sentence:
		s = re.search("didn't (.)+\\.", sentence)
		s2 = 'did ' + sentence.split(' ')[3] + ' it'
		return "I don't think you {} today, I think you {}!".format(s.group()[:-1], s2)
	else:
		s = sentence.split(' ')[2][:-2]
		s1 = ' '.join(sentence.split(' ')[2:])[:-1]
		s2 = "didn't " + s + ' at all'
		return "I don't think you {} today, I think you {}!".format(s1, s2)