Gerund
When -ing forms are used like nouns, they are called gerunds. A gerund can be the subject, object or complement of a verb.
- Flying (subject) makes me sick.
- Trespassing (subject) is prohibited.
- Smoking (subject) is injurious to health.
- We don’t allow smoking (object) in our house.
- I enjoy swimming (object) in the sea.
- My favourite activity is reading. (complement)
- The thought of failing never entered his head. (object of the preposition of)