Create 5 MCQ questions for a course titled "React" about "react for beginners".…
- User
User: Create 5 MCQ questions for a course titled "React" about "react for beginners". Each question should have 4 options and specify the correct answer. Format like: Q1. Question text? a) Option1 b) Option2 c) Option3 d) Option4 Answer: Option User: Create 5 MCQ questions for a course titled "React" about "react for beginners". Each question should have 4 options and specify the correct answer. Format like: Q1. Question text? a) Option1 b) Option2 c) Option3 d) Option4 Answer: Option Assistant:
- Assistant
Q1. What is React primarily used for? a) Server-side scripting
b) Building user interfaces
c) Database management
d) Styling web pages
Answer: b) Building user interfacesQ2. What is a React component?
a) A function or class that returns HTML elements to be rendered
b) A CSS styling method
c) A backend API endpoint
d) A database table
Answer: a) A function or class that returns HTML elements to be renderedQ3. Which of the following is the correct way to create a React component?
a)function MyComponent() { return <div>Hello</div>; }
b)<MyComponent>function() {}</MyComponent>
c)createComponent() { return "Hello"; }
d)<div>function MyComponent() {}</div>
Answer: a)function MyComponent() { return <div>Hello</div>; }Q4. What does JSX stand for in React?
a) JavaScript XML
b) Java Syntax eXtension
c) JavaScript eXecutable
d) JavaScript External
Answer: a) JavaScript XMLQ5. How do you pass data from a parent component to a child component in React? a) Using state b) Using props c) Using localStorage d) Using cookies Answer: b) Using props
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.