Ernest Hemingway's A Farewell to Arms was actually very much inspired by his own life experiences during World War I. Hemingway was denied enlistment into the army due to poor vision, so he became a volunteer ambulance driver for the Red Cross instead, just like his protagonist Frederic Henry. Also, just like Frederic, Hemingway was stationed in Milan by the Red Cross and was also severely injured by an Austrian mortar shell. He was then evacuated to a hospital in Milan, just like Frederick (The Hemingway Resource Center, "Ernest Hemingway Biography: World War I").
In the hospital, Hemingway also fell in love with a nurse named Agnes von Kurowsky just as Frederic falls in love with a nurse named Catherine. However, unlike Frederic and Catherine, Hemingway's relationship with Agnes did not go very far. Historians debate how physical Hemingway's relationship became with Agnes, especially since nurses were forbidden to have relationships with patients. What is known is that they "managed love notes, dinners," and there is speculation that there was "possibly more" (People, "Ernest Hemingway & Agnes Von Kurowsky"). Once Hemingway was sent back to the States to recover, the couple also "exchanged love letters for several months"; however, by March 1919, Agnes became engaged to an Italian nobleman (People).