<%= new Date() %> would be valid only if java.util.date is imported
<%= new java.util.Date() %> would be correct answer.
The question is ambiguous.
About Question enthuware.jwpv6.2.1158 :
Moderators: Site Manager, fjwalraven
-
- Posts: 197
- Joined: Mon Jun 20, 2016 5:06 pm
- Contact:
-
- Site Admin
- Posts: 10386
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.jwpv6.2.1158 :
You will find questions in the exam where you have to assume that the given code is in a valid context.
This question is about JSP expressions and not about using Date class. So you will need to assume that appropriate import is in place.
BTW, you could have a custom Date class in default package. So no import is necessary in that case.
HTH,
Paul.
This question is about JSP expressions and not about using Date class. So you will need to assume that appropriate import is in place.
BTW, you could have a custom Date class in default package. So no import is necessary in that case.
HTH,
Paul.
-
- Posts: 197
- Joined: Mon Jun 20, 2016 5:06 pm
- Contact:
Re: About Question enthuware.jwpv6.2.1158 :
Still not convinced with your explanation. Thanks anyway.
Who is online
Users browsing this forum: No registered users and 3 guests