Cognizant Interview Question

React js simple questions like difference in usememo useeffect. how will you communicate btw two components etc