programming languages Online Quiz - 99
Description: programming languages Online Quiz - 99 | |
Number of Questions: 20 | |
Created by: Aliensbrain Bot | |
Tags: programming languages |
The process of writing the state of an object to a byte stream is called as
servlet.xml is the file used to define a servlet mapping
Through _________ , you can control what parts of a program can access the members of a class
Given the JSP code: and the Classic tag handler code: 5. public int doStartTag() throws JspException { 6. // insert code here 7. // return int 8. } Assume there are no other "foo" attributes in the web application. Which invocation on the pageContext object, inserted at line 6, assigns "bar" to the variable x?
Given: 11. List list = // more code here 12. Collections.sort(list, new MyComparator()); Which code will sort this list in the opposite order of the sort in line 12?
Given: 11. public static void append(List list) { list.add(”0042”); } 12. public static void main(String[] args) { 13. List intList = new ArrayList(); 14. append(intList); 15. System.out.println(intList.get(0)); 16. } ‘What is the result?
Given: classA {} class B extends A {} class C extends A {} class D extends B {} Which three statements are true? (Choose three.)
A programmer has an algorithm that requires a java.util.List that provides an efficient implementation of add(0,object), but does NOT need to support quick random access. What supports these requirements?
Servlet A receives a request that it forwards to servlet B within another webapplication in the same web container. Servlet A needs to share data with servlet B and that data mustnot be visible to other servlets in A's web application. In which object can the data that A shares with Bbe stored?
what is the output of the following Program
What is the output of the following Program.
Output of the following program
Output of the following program
what is the output of the following program
what is the output of the following program
1.main() { char s[ ]="man"; int i; for(i=0;s[ i ];i++) printf("%c%c%c%c",s[ i ],(s+i),(i+s),i[s]); }
main() { static int var = 5; printf("%d ",var--); if(var) main(); }
main() { int c[ ]={2.8,3.4,4,6.7,5}; int j,*p=c,*q=c; for(j=0;j<5;j++) { printf(" %d ",*c); ++q; } for(j=0;j<5;j++){ printf(" %d ",*p); ++p; } }
main() { int i=-1,j=-1,k=0,l=2,m; m=i++&&j++&&k++||l++; printf("%d %d %d %d %d",i,j,k,l,m); }