They're the same. C++ typically calls them functions. Java typically refers to them as methods.
Methods are typically associated with a class.
You'll occasionally hear "class function" too, which is just a method.
It doesn't matter, people will know what you're talking about if you call them either.