Skip to content

Instantly share code, notes, and snippets.

@mayankdawar
Created February 22, 2020 19:57
Show Gist options
  • Select an option

  • Save mayankdawar/3e2c783871c35ef04d58d5d32394dc3f to your computer and use it in GitHub Desktop.

Select an option

Save mayankdawar/3e2c783871c35ef04d58d5d32394dc3f to your computer and use it in GitHub Desktop.
For each string in wrds, add ‘ed’ to the end of the word (to make the word past tense). Save these past tense words to a list called past_wrds.
wrds = ["end", 'work', "play", "start", "walk", "look", "open", "rain", "learn", "clean"]
lst = []
for i in wrds:
i = i + "ed"
lst.append(i)
past_wrds = lst
@misspage
Copy link

For each word in the list verbs, add an -ing ending. Save this new list in a new list, ing

verbs = ["kayak", "cry", "walk", "eat", "drink", "fly"]
accum =[]
for ing in verbs:
x= ing + "ing"
accum.append(x)
print(accum)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment