Part of it is also culture. Where I grew up, if our eyes meet, then we should acknowledge it with a smile, a greeting or both.
But, if you're alone in a foreign country, especially if you don't know much about the language - any semblance of communication goes a long way. In many cases, a smile is good enough.
- If you make eye contact with someone in the street by accident, do you smile?
- If you enter a lift/elevator with a stranger, and you're alone with them, do you say hello?
- If you enter a shop, do you smile at and greet the shopkeeper?
My answer to all of these questions would be YES, this is what I was socialized to do in Kansas with fairly low population and lots of farming. Even though I grew up in a city, people are still pretty friendly.
I once traveled with persons from other parts of the U.S. to Europe. I liked my trip, but honestly I felt so happy when I got back home where people smiled warmly and greeted me even if they did not know me.
I live in the country, but work in a city. In the country, our norm is to wave and smile at anyone who drives by (as we try to figure out whether we actually know the person or not). In the city we do not do that.