Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

javaranch mock question

 
jim yin
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which of the following dtd code is valid?
a)<!ELEMENT test (#CDATA)>
b)<!ELEMENT test (#PCDATA)>
c)<!ELEMENT test (#ANY)>
d)<!ELEMENT test (this,that)*>
<!ELEMENT this(#PCDATA)>
<!ELEMENT that(#PCDATA)>
Answer : b

d) is not right because subelements must follow the described order and cannot be repeated, right?
 
Jayadev Pulaparty
Ranch Hand
Posts: 662
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jim,
The answer for this exact question has been posted sometime back. The reason why "d" is not the answer is the missing space b/w this and (#PCDATA) i.e.,
it should be --- this (#PCDATA)
and not --- this(#PCDATA)
 
jim yin
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks. Well, I really got short memory. I remember I also saw that one.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic