Multiple choice technology programming languages

A bean with a property color is loaded using the following statement Which of the following statements may be used to set the of color property of the bean. Select the one correct answer.

  1. <jsp:setColor id="fruit" property="color" value="white"/>

  2. <jsp:setColor name="fruit" property="color" value="white"/>

  3. <jsp:setValue name="fruit" property="color" value="white"/>

  4. <jsp:setProperty name="fruit" property="color" value="white">

  5. <jsp:setProperty name="fruit" property="color" value="white"/>

Reveal answer Fill a bubble to check yourself
E Correct answer
Explanation

The correct JSP syntax for setting bean properties is . The element name is setProperty, not setColor or setValue. Option D is missing the closing slash.