A two-year-old Port Coquitlam, B.C., girl is recovering after being attacked by a coyote on Monday while she was playing in an elementary school yard, CTV News has learned.

The toddler suffered puncture wounds to the head and ears when she was attacked by the coyote, which has since been caught and shot dead by local conservation officers.

A necropsy revealed the coyote had consumed dog kibble and table food scraps prior to the attack which occurred at around 10:40 a.m. on the grounds at Central Elementary School located in the 2200-blk of Central Avenue.

Adults in the area were able to rescue the child and chase the coyote away.

B.C. Conservation officer Terry Myroniuk said the attack likely occurred because someone had been feeding the coyote, something people should never do.

Myroniuk said wild animals, who are fed kitchen scraps, quickly lose their fear of humans and tend to wander into residential areas in search of food.

"This is a classic example of why people shouldn't feed animals,'' he said.

Conservation officers were quickly able to identify the coyote, which had lost a lot of body fur, but had a belly full of nutritious food.

Myroniuk said he believes the girl was released from hospital after receiving medical treatment. "She had a lucky escape,'' he said, adding that she was lucky that adults were around to intervene.