In japan, they know foreign people will have problems so they do things to make it easier for them. For example, in a macdonalds, there's a big paper on the counter with pictures of what they have. So if the one behind the counter sees any language difficulty they use simple english and point on the paper

Oh, and btw, they don't have mayonaise in macdonalds in Japan :p (I like mayo...)
Same goes for restaurants, with the plastic models (but you probably heard of those already).
And other shops, well, they always have a digital cash register or a calculator at hand with a digital display, so if you don't understand the amount they are saying, you can still read it (and they know that, so they are very helpful).
And be prepared to hear a LOT of "Irasshaimase!" when you enter a shop. (from everyone that works there, if you pass them).
So that's for the language barrier

They do of course like it when you try to speak japanese

and like eddie said, bow or nod

(as they will do it too)
__________________
My Japan Blog (and about Ayu, Anime,Figures,...)
Japan 2007 Trip Travel Blog (May 4-18,Ayu Concert x2)
Japan 2008 Trip Travel Blog (March 23-April 08,Ayu,gazette,X-Japan Concert & Tokyo Anime Fair)
Japan 2009 Trip Travel Blog (April 26-May 13,Ayu & Perfume Concert & Dolls Party 21)
Tokyo 2009 (Dec 27-Jan 3, Ayu CDL Concert)
Japan 2010 (April 6-23, Ayu & Kuu Concert?)
January 28th 2010: The day everything changed for international Ayu fans. <3