Need to change object prefix

I have number of objects which starts with prefix XXX (just for example). I want to replace all these objects with new prefix YYY. How can i do it. Please let me know the best way to do it. Thanks a lot.