Read the sentence.
Cooking can be a learning experience.
Which correctly identifies the function of the gerund in this sentence?
subject
subject compliment
object of the preposition
direct object