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

mock exam question

 
rick collette
Ranch Hand
Posts: 208
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which jsp lines are correct?
1) <%! String myString=�Hello� %>
2) <% String myString=request.getServerName() %>
3) <%= out.print(�Hello�) %>
4) <%= �Hello� %>
I know 30 is wrong, and 4) is correct. Why 1) and 2) are wrong?
 
James Kwan
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rick,
1) and 2) are wrong because the semicolon is missing.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic