| Author |
Mock Exam Question doubt
|
Joshua Antony
Ranch Hand
Joined: Jun 05, 2006
Posts: 254
|
|
Consider the following JSP code (See exhibit). What will it print for the very first request to this page as well as the web application that contains this page? Select 1 correct option. A.It will print Hello! B.It will print Hello and will set the count attribute in the session. C.It will throw a NullPointerException at request time. D.It will not compile. Answer given is B. Should'nt it be C since will return null for the first time and hence will result in NPE ?
|
SCJP,SCWCD, Into ATG now!
|
 |
Xenon Parker
Greenhorn
Joined: Mar 06, 2008
Posts: 9
|
|
|
It should give a NullPointerException.
|
 |
 |
|
|
subject: Mock Exam Question doubt
|
|
|