Answer: Adult Toxocara cati; the presence of this adult worm represents either environmental contamination (e.g. from an infected cat) or spurious passage by the child.
This case generated an excellent, entertaining, and somewhat disturbing (!) discussion. As many of you correctly noted, this is an adult Toxocara species. It has a similar appearance to Ascaris lumbricoides, but can be differentiated by the presence of the pronounced short, wide cervical alae:
The shape of the alae allow it to be differentiated from other Toxocara species. Note that the alae narrow towards that anterior end, giving the appearance of an arrow (image by my excellent parasitology technologist, Emily Fernholz).
Humans are not a definitive host, but can acquire infection with the larval form of the worm when accidentally ingesting eggs in contaminated soil or infected paratenic hosts. The larvae cannot mature in humans, but can migrate throughout the body causing a potentially serious condition called visceral larva migrans.
So how did this adult worm end up in a human host? Well, we can't really say for sure that it actually was IN this patient since it was noted outside of the body during bathing. Therefore it could have been expelled by family cat and simply ended up in the bathtub.
Alternatively, it could be that the child had ingested an adult or immature worm from the environment (the term kitty spaghetti will stick with me forever! See the comments for more information) and it had passed through her intestinal tract and was expelled intact. Authors from the US CDC published a interesting series of cases like this in 1998. You can read the article HERE.
Regardless of the scenario, it is clear that there is an infected household cat that needs to be treated. As I mentioned above, eggs that are shed from infected cats can mature in the environment and pose an infectious risk to humans (i.e. visceral larva migrans).
Thank you all for excellent comments!