Computer Notes

Reviews
Stats
views:
31
rating:
not rated
reviews:
0
posted:
8/19/2009
language:
English
pages:
0
JAVA ~~~~ basics of EJB, servlets how is inheritance built in java(extends) why is java efficient. Various Steps in Servlets what do you know about EJB, corba, xml, servlets, asp, applets, rmi, wml. what is servlet chaining. what is object oriented. what is VSS, why is it used. what is polymorphism? how is it acheieved in java. what alt in applet. how do you pass parameters to the applet. what is the difference between alternate code in applet tag and code within tags and what is a1==a2 ? what is a1.equalTo(a2)? what is the difference between runnable & thread? why is runnable used. how is data shared from one form to another form. how & why is Java platform independent. what internally happens when java file is compiled what is "this"? b.addActionListener(this). what is the parameter to actionlistener. how does servlet provide security. what does JVM do. 1. What is the difference between C++ & Java? 2. Explain RMI Architecture? 3. How do you communicate between Applets & Servlets? 4. What is the use of Servlets? 5. What is JDBC? How do you connect to the Database? 6. In an HTML form I have a Button, which makes us to open another page in 15 seconds. How will do you that? 7. What is the difference between Process and Threads? 8. How will you initialize an Applet? 9. What is the order of method invocation in an Applet? 10. How will you pass values from HTML page to the Servlet? 11. How will you communicate between two Applets? 12. What are statements in JAVA? 13. What is JAR file? 14. What is the base class for all swing components? 15. What is JFC? 16. What is Difference between AWT and Swing? 17. How will you call an Applet using a Java Script function? 18. How can you push data from an Applet to Servlet? 19. What are 4 drivers available in JDBC? 20. How you can know about drivers and database information? 21. And in what situation, each of the four drivers are used? 22. How will you perform transaction-using JDBC? 23. Suppose server object is not loaded into the memory, and the client request for it, what will happen? 24. Can you load the server object dynamically? If so, what are the major 3 steps involved in it? 25. What are the benefits of Swing over AWT? 26. What is Servlet API used for connecting database? 27. What is difference in between Java Class and Bean? 28. What is the difference between Application and Applet? 29. What is the root class for all Java classes? 30. What is polymorphism? 31. What is the exact difference in between Unicast and Multicast object? Where we will use? 32. What is the difference in between C++ and Java? Can you explain in detail? 33. Have you used threads in Servelet? 34. In a Container there are five components. I want to display the all the components names, how will you do that one? 35. Why there are some null interfaces in Java? What does it mean? Give me some null interfaces in JAVA? 36. Tell me the latest versions in JAVA related areas? 37. Explain 2 tier and 3 tier Architecture? 38. How have you done validation of the fields in your project? 39. What are the main difficulties that you are faced in your project? 40. What is meant by cookies? Explain? what is the difference between rmi registry & os agent. what is the layout of the tool bar. what is statement in java. what are the 5 packages in java. (java.lang, java.util, java.sql, java.awt, java.io) how do you send data from form to server?(get & post) what is xml and dhtml Q) ans : Q) int i = 45678; int j = ~i; ~i means (-i) - 1; System.out.println(j); -45679 default layout for : panel = flowLayout Applet = Frame = Q) FlowLayout BorderLayout you cannot override a non-static method with a static method and Vice Versa Q) Package is declared first and then importing........ Q) In command line arguments.. java counts from 0,1,2... Q) An identifier can begin with a letter (most common) or a dollar sign($) or an underscore(_). Q) Method level variables are not given default values and if you attempt to use one before it has been initialised it will cause the ERROR Q) Any class derived from an abstract class must either define all of the abstract methods or be declared abstract itself. Q) Integer ten=new Integer(10); Long nine=new Long (9); System.out.println(ten + nine); int i=1; System.out.println(i + ten); 1) 19 followed by 20 2) 19 followed by 11 3) Error: Can't convert java lang Integer *********************** 4) 10 followed by 1 The wrapper classes cannot be used like primitives. Wrapper classes have similar names to primitives but all start with upper case letters. Thus in this case we have int as a primitive and Integer as a wrapper. The objectives do not specifically mention the wrapper classes but don't be surprised if they come up. Q) Which of the following statements are true? Methods cannot be overriden to be more private JAVA:1.What is the difference between an Abstract class and interface? 2.What is user defined exception? 3.What do you know about her garbage collector? 4.What is the difference between java and c++? 5.In an HTML form I have a button which makes us to open another page in 15 seconds. How will you do this ? 6.What is the difference between process and threads? 7.What is update method called? 8.Have you ever used Hash table and Directory? 9.What are statements in Java? 10.What is a JAR file? 11.What is JNI? 12.What is the base class for all swing components? 13.What is JFC? 14.What is the difference between AWT and Swing? 15.Considering notepad/IE or any other thing as process, what will happen if you start notepad or IE three times? Where three processes are started or three threads are started? 16.How does thread synchronization occur in a monitor? 17.Is there any tag in HTML to upload and download files? 18.Why do you canvas? 19.How can you know about drivers and database information? 20.What is serialization? 21.Can you load the server object dynamically? If so what are the three major steps involved in it? 22.What is the layout for toolbar? 23.What is the difference between Grid and Gridbaglayout? 24.How will you add panel to a frame? 25.Where are the card layouts used? 26.What is the corresponding layout for card in swing? 27.What is light weight component? 28.Can you run the product development on all operating systems? 29.What are the benefits if Swing over AWT? 30.How can two threads be made to communicate with each other? 31.What are the files generated after using IDL to java compiler? 32.What is the protocol used by server and client? 33.What is the functionability stubs and skeletons? 34.What is the mapping mechanism used by the java to identify IDL language? 35.What is serializable interface? 36.What is the use of interface? 37.Why does java not support multiple inheritance? 38.Why java is not fully objective oriented? 39.What is the root class for all java classes? 40.What is polymorphism? 41.Suppose if we have a variable ‘I’ in run method, if I can create one or more thread each thread will occupy a separate copy or same variable will be shared? 42.What are virtual functions? 43.Write down how will you create binary tree? 44.What are the traverses in binary tree? 45.Write a program for recursive traverse? 46.What are session variable in servlets? 47.What is client server computing? 48.What is constructor and virtual function? Can we call a virtual function in a constructor? 49.Why do we use OOPS concepts? What is its advantage? 50.What is middleware? What is the functionality of web server? 51.Why is java not 100% pure OOPS? 52.When will you use an interface and abstract class? 53.What is exact difference in between Uni-cast and Multi-cast object? Where will it be used? 54.What is the functionality of Prepared statement? 55.What is meant by Static query and Dynamic query? 56.What are Normalization rules? Define Normalization? 57.What is meant by servlet? What are the parameters of service method? 58.What is meant by session? Explain something about HTTP session class? 59.In a container there are 5 components. I want to display all the component names, how will you do that? 60.Why there are some null interfaces in Java? What does it mean? Give some null interface in Java? 61.Tell some latest versions in Java related areas? 62.What is meant by class loader? How many types are there? When will we use them? 63.What is meant by flickering? 64.What is meant by distributed application? Why are we using that in our application? 65.What is the functionality of the stub? 66.Explain about version control? 67.Explain 2-tier and 3-tier architecture? 68.What is the role of web server? 69.How can we do validation of the fields in a project? 70.What is meant by cookies? Explain the main features? 71.Why Java is considered as platform independent? 72.What are the advantages of Java over C++? 73.How Java can be connected to a database? 74.What is thread? 75.What is difference between Process and Thread? 76.Does Java support multiple inheritance? If not, what is the solution? 77.What are abstract classes? 78.What is an interface? 79.What is the difference between abstract class and interface? 80.What are adapter classes? 81.What is meant by wrapper classes? 82.What is JVM? 83.What is JRE? 84.What is J2EE? 85.What is JNI? 86.What are swing components? 87.What do you mean by light weight and heavy weight components? 88.What is meant by function overloading and function overriding? 89.Does Java support function overloading, pointers, structures, unions or linked lists? 90.What do you mean by multi-threading? 91.What are byte codes? 92.What are streams? 93.In an HTML form I have a button which makes us to open a new page in 15 seconds. How will you do that? Advance Java Questions: 94.What is RMI? 95.Explain about RMI architecture? 96.What are servlets? 97.What is the use of servlets? 98.How will you pass values from HTML page to the servlet? 99.How do you load an image in a servlet? 100.What is the purpose of applet programming? 101.How ill you communicate between two applets? 102.What s the difference between servlets and applets? 103.How do you communicate between applets and servlets? 104.What is the difference between CGI and servlet? 105.In the servlets, we are having a web-page that is invoking servlets, username and password? Which is checks in database? Suppose the second page also if we want to verify the same information whether it will connect to the database or it will be used previous information? 106.What is the difference between RMI and Servlets? 107.How will you call an applet using a Java script function? 108.How can you push data from an applet to a servlet? 109.What are the 4 drivers available in JDBC? At what situation are four of the drivers used? 110.If you are truncated, using JDBC, how can you know that how much data is truncated? 111.How will you perform truncation using JDBC? 112.What is the latest version of JDBC? What are the new features added in that? 113.To a server method, the client wants to send a value 20, with this value exceeds to 20 a message should be sent to the client. What will you do for achieving this? 114.What is the difference between RMI registry and OS agent? 115.How do you invoke a servlet? What is the difference between doPost method and doGet method? 116.What is the difference between HTTP servlet and Generic servlet? Explain about their methods and parameters? 117.Can we use threads in servlets? 118.Write a program on RMI and JDBC using stored procedure? 119.How do you swing an applet? 120.How will you pass parameters in RMI? Why do you serialize? 121.In RMI, server object is first loaded into memory and then the sub-reference is sent to the client. True or False? 122.Suppose server object not loaded into the memory and the client request for it. What will happen? 123.What is the web server used for running the servlets? 124.What is servlet API used for connecting database? 125.What is bean? Where can it be used? 126.What is the difference between Java class and Bean? 127.Can we send objects using sockets? 128.What is the RMI and Socket? 129.What is CORBA? 130.Can you modify an object in corba? 131.What is RMI and what are the services inRMI? 132.What are the difference between RMI and CORBA? 133.How will you initialize an applet? 134.What si the order of method invocation in an applet? 135.What is ODBC and JDBC? How do you connect the database? 136.What do you mean by Socket programming? 137.What is the difference between Generic servlet and HTTP servlet? 138.What do you mean by COM? 139.What do you mean by DCOM? 140.What is e-commerce? JAVA QUESTIONS 1. ODBC 2. HTML 3. RISC Ans. Open Database Connectivity. Ans. Hyper Text Markup Language Ans. Reduced Instruction Set Computing 4. ASCII Ans. American Standard Code For Information Interchange 5.ANSI Ans. American National Standard Institute. 6. XML Ans. Extended Markup Language 7. FLOPS Ans. Floating Point Operating Per Second 8. SQL Ans. Sequential Query Language 9. QBE Ans. Query By Example 10. ALE Ans. Address Latch Enable 12. RPC Remote procedure call 11. What is lagging in DBMS ? Ans. Reduced Redundancy. What is JAVA ? Java is a pure object oriented programming language, which has derived C syntax and C++ object oriented programming features. Is a compiled and interpreted language and is platform independent and Can do graphics, networking, multithreading. It was initially called as OAK. What r the four cornerstones of OOP ? Abstraction : Can manage complexity through abstraction. Gives the complete overview of a particular task and the details are handled by its derived classes. Ex : Car. Encapsulation : Nothing but data hiding, like the variables declared under private of a particular class are accessed only in that class and cannot access in any other the class. Inheritance : Is the process in which one object acquires the properties of another object, ie., derived object. Polymorphism : One method different forms, ie., method overriding and interfaces are the examples of polymorphism. what is downcasting ? Doing a cast from a base class to a more specific class. The cast does not convert the object, just asserts it actually is a more specific extended object. e.g. Dalamatian d = (Dalmatian) aDog; Most people will stare blankly at you if you use the word downcast. Just use cast. What is Java Interpreter ? It is Java Virtual Machine. ie., a java program compiles the Unicode to intermediary code called as Bytecode which is not an executable code. that is executed by Java interpreter. What are Java Buzzwords ? Simple : Easy to learn. Secure : Provided by firewalls between networked applications. Portable : Can be dynamically downloaded at various platforms connect to internet. OOP : Four Corner stones. Multithread : Can perform more than one task concurrently in a single program. Robust : overcomes problems of de-allocation of memory and exceptions. Interpreted Distributed Dynamic : : : Convert into byte code and the executes by JVM. Concept of RMI. Verifying and accessing objects at run time. What are public static void main(String args[]) and System.out.println() ? Public keyword is an access specifier. Static allows main() to be called without having to instantiate a particular instance of class. Void does not return any value. main() is the method where java application begins. String args[] receives any command line arguments during runtime. System is a predefined class that provides access to the system. out is output stream connected to console. println displays the output. What are identifiers and literals ? Identifiers are the variables that are declared under particular datatype. Literals are the values assigned to the Identifiers. What is Typed language ? This means that the variables are at first must be declared by a particular datatype whereas this is not the case with javascript. Scope and lifetime of variables ? scope of variables is only to that particular block lifetime will be till the block ends. variables declared above the block within the class are valid to that inner block also. Casting Incompatible types ? Can be done either implicitly and explicitly. ie., int b = (int) c; where c is float. There are two types of castings related to classes : 1) unicast and 2)multicast. Declaration of Arrays ? int a[] = new int[10]; int a[][] = new int[2][2]; What does String define ? String is an array of characters, but in java it defines an object. and the variable of type string can be assigned to another variable of type String. What r bitwise operators and bitwise logical operators ? ~, &, |, ^, >>, >>>, <<, &=, != and ~, &, | How do you define break and Label ? We can declare as break