Our miscommunication is compounded when we use language in a lazy manner ~ for instance, when we take grammatical shortcuts, or when we compress a sentence into a phrase, a phrase into a word. This shorthand may be convenient, but it invites misunderstanding.
I was reminded of the gap between intent and effect as I read an article on evolution that sported a title to hook the reader ~ 'Bird Mimic' Dinosaur Hints That Wings Evolved for Show, Not Flight. Even scientists, who (along with mathematicians) should use language with scrupulous care, lapse into shorthand when speaking with other scientists. Alas, the shorthand seeps through to a wider audience which may not grasp the fuller meaning, a situation ripe for misinterpretation.
The article's title is a variant on one of the most common and egregious examples of misleading shorthand. If you make a statement such as "wings evolved for show", or "lungs evolved so that animals could live on land", the reader may be forgiven for hearing intent, when in fact all that can be confidently stated is effect. Science assumes no prime mover, no outside intelligence which is making choices. Quite the opposite. Over evolutionary time, it has been demonstrated many times that morphological changes occur by chance. Millions of chances, in fact. Genetic mutation, genetic drift, or fortuitous changes in the environment happen in a random fashion. The organism or species didn't sit up one day and think "Hmm, I think I'll evolve longer fangs to give me an edge in the hunt." Rather, (usually in small increments, but sometimes in larger ones) subtle mistakes in copying the genetic code result in a change in anatomy or physiology (structure or function). If the effect enhances the organism's ability to survive and reproduce, the errant gene will be passed on to the next generation. Far more often, the effect hinders survival, and vanishes from the gene pool. Those successful "mistakes", if they spread throughout the population, become the new norm. Thus, gradually, do gill-breathers evolve into lung-breathers, and dinosaurs evolve into birds. Evolution takes time, but time is present in abundance. If you look around at all the organisms living on Earth, those are the genetic successes. They are far, far outnumbered by the genetic failures, which are no longer with us.
Further, it is quite common in evolutionary history for an organism to develop a physical feature or a behavior which serves one purpose (a mating display enhanced by feathers), and over generations to observe that feature prove useful for another purpose (flying).
In the context of evolution, the linguistic distinction I've been describing is important. When a professor or science writer says something like "giraffes evolved long necks to be able to reach foliage growing higher from the ground", he/she is using shorthand. The more accurate description would sound something like "over time, some giraffes evolved longer necks as a result of a cascading series of genetic mutations, which had the fortunate effect of allowing them to reach foliage growing higher from the ground. The longer-necked giraffes thus had a feeding advantage over their shorter-necked kin, who eventually died out." Given that even lay people refer to evolutionary change sometimes, and scientists much more often, one can understand how handy it is to resort to shorthand. Professional journals would be long and cumbersome if we didn't all agree on the assumption that "X evolved to accomplish Y" is really a shortened version of "X survived because it happened to acquire Y trait through mutation".
The key slippery term is that modest and ambiguous word "to". If I say, "I'm going out to get groceries", that's a legitimate statement of intent, with a legitimate agent to perform it ~ me. Unfortunately, intent is what some readers and listeners assume when they come across a statement like "plants evolved flowers to enhance their reproductive success and expand the number of ecological niches they could inhabit". That is not a statement of intent. It is a shorthand statement of effect. It is critical to understand the distinction.