Question: You are working with an XML document that uses an XML schema. How do you ensure that an attribute must be specified for its corresponding element?

  1. Set the type attribute to `xs:required`.
  2. Set the `use` attribute to `required`.
  3. Set the minLength attribute to 1.
  4. Set the minOccurs attribute to 1.

Answer: The correct answer of the above question is Option B:Set the `use` attribute to `required`.