Frage im Vorstellungsgespräch bei Infosys

JavaScript Basics Explain the difference between var, let, and const. What is a closure in JavaScript? Can you give an example? Explain hoisting in JavaScript. What are promises? How do they work? What is the event loop? How does it work? What is the difference between synchronous and asynchronous code? Advanced JavaScript What are higher-order functions in JavaScript? Can you provide an example? Explain the bind(), call(), and apply() methods. React.js Specific Explain the virtual DOM and how it works in React. What are React components? Differentiate between class and functional components. What are hooks in React? Can you explain useState and useEffect? How do you optimize performance in a React application? What are higher-order components (HOCs) in React? Explain the concept of Redux and how it integrates with React. What is the difference between controlled and uncontrolled components in React?