What is object-oriented programming and how does it differ from functional programming?