I am creating an application that will store a hierarchical set of elements in an XML file, and I wonder what industry standard stores collections in XML. Which of the following two formats is preferred? (If there is another option that I do not see, please let me know.)
Option A
<School> <Student Name="Jack" /> <Student Name="Jill" /> <Class Name="English 101" /> <Class Name="Math 101" /> </School>
Option B
<School> <Students> <Student Name="Jack" /> <Student Name="Jill" /> </Students> <Classes> <Class Name="English 101" /> <Class Name="Math 101" /> </Classes> </School>
source share