The confusion in using like or as is caused by a lack of understanding of the words’ roles. In formal writing, like is used as a preposition, telling where, when or how the noun in the sentence is doing whatever it may be doing. As is used as a conjunction, joining two clauses.
When to use like instead of as
Most of the time, like compares two things.
Here, we’re comparing two things (he and Oscar Wilde), so like should be used.
The same goes for this next sentence, where we’re comparing a mother and daughter:
Even though the verb has follows as, it actually belongs to the noun phrase The little girl. We need like to modify her mother.
When to use as instead of like
Frequently, as can be replaced by the way.
Because there is a verb after like (does), the conjunction as should be used. It’s easy to say that about this sentence because as can be replaced by the way.
Let’s look at another example.
At first glance, there appears to be no verb after like. However, when speaking, we often leave out verbs that are already implied. The implied verb is play, as in he used to play cricket. Like should be changed to as.