${calcAge(client.birthDate) < 25}
${calcAge[client.birthDate] < 25}
${funct:age(client.birthDate) < 25}
${funct:age[client.birthDate] < 25}
${funct:calcAge(client.birthDate) < 25}
第1题:
有以下程序:
include <iostream>
include <string>
using nameSpace std;
class person
{
int age;
Char * name;
public:
person ( int i, Char * str )
{
int j;
j = strlen( str ) + 1;
name = new char[ j ];
strcpy( name, str );
age = i;
}
~person()
{
delete name;
cout<<"D";
}
void display()
{
cout<<name<<":"<<age;
}
};
int main()
{
person demo( 30,"Smith" );
demo.display();
return 0;
}
则该程序的输出结果为:【 】。
第2题:
下列程序的输出结果为 main() { union u {char *name; int age; int income;}s s.name="WANGLIONG"; s.age=28; s.income=1000; printf("%d\n",s.age); }
A.28
B.1000
C.0
D.不确定
第3题:
此题为判断题(对,错)。
第4题:
You are building a dating web site. The client’s date of birth is collected along with lots of other information.The Person class has a derived method, getAge():int, which returns the person’s age calculated from thedate of birth and today’s date. In one of your JSPs you need to print a special message to clients within theage group of 25 through 35. Which two EL code snippets will return true for this condition? ()
第5题:
You are building a web application with a scheduling component. On the JSP, you need to show the currentdate, the date of the previous week, and the date of the next week. To help you present this information,you have created the following EL functions in the ’d’ namespace: name: curDate; signature: java.util.DatecurrentDate() name: addWeek; signature: java.util.Date addWeek(java.util.Date, int) name: dateString;signature:java.util.String getDateString(java.util.Date) Which EL code snippet will generate the string for the previousweek?
第6题:
Youarebuildingawebapplicationwithaschedulingcomponent.OntheJSP,youneedtoshowthecurrentdate,thedateofthepreviousweek,andthedateofthenextweek.Tohelpyoupresentthisinformation,youhavecreatedthefollowingELfunctionsinthe’d’namespace:name:curDate;signature:java.util.DatecurrentDate()name:addWeek;signature:java.util.DateaddWeek(java.util.Date,int)name:dateString;signature:java.util.StringgetDateString(java.util.Date)WhichELcodesnippetwillgeneratethestringforthepreviousweek?
A.${d:dateString(addWeek(curDate(),-1))}
B.${d:dateString[addWeek[curDate[],-1]]}
C.${d:dateString[d:addWeek[d:curDate[],-1]]}
D.${d:dateString(d:addWeek(d:curDate(),-1))}
第7题:
You are building a dating service web site. Part of the form to submit a client’s profile is a groupIIof radio buttons for the person’s hobbies: 20.Hiking
21.Skiing
22.SCUBA Diving 23. After the user submits this form, a confirmation screen is displayed with these hobbies listed. Assume thatan application-scoped variable, hobbies, holds a map between the Hobby enumerated type and the displayname. Which EL code snippet will display Nth element of the user’s selected hobbies?()
第8题:
Your Web site uses custom Themes. Your Web site must support additional Themes based on the user‘s company name. The company name is set when a user logs on to the Web site. The company‘s Theme name is stored in a variable named ThemeName. You need to use this variable to dynamically set the Web site‘s Theme.What should you do?()
A.
B.
C.
D.
第9题:
You are building a dating web site. The client’s date of birth is collected along with lots of other information.You have created an EL function with the signature: calcAge(java.util.Date):int and it is assigned to the name, age, in the namespace, funct. In one of your JSPsyou need to print a special message to clients who are younger than 25. Which EL code snippet will returntrue for this condition?()
第10题:
Given an EL function foo, in namespace func, that requires a long as a parameter and returns a Map, which two are valid invocations of function foo?()