Search Interview Questions | Click here and help us by providing the answer. Click Correct / Improve and please let us know. |
|
|||
|
| ||||
| Interview Questions and Answers for 'Pwc' - 6 question(s) found - Order By Rating | ||||
| ||||
| Ans. using session attribute. session.setAttribute("userId",userId); in first jsp int userId=session.getAttribute("userId"); in second jsp; | ||||
| ||||
| Ans. TakeScreenshot th = TakeScreenshot(driver); //Enable the driver object to take screenshot File src = th.getScreenShotAs(OutputType.FILE); FileUtils.copyFilesrc("locationWhereUWantToPlaceTheScreenshot.jpg"); | ||||
| ||||
| Ans. clone() - Creates and returns a copy of this object. equals() - Indicates whether some other object is "equal to" this one. finalize() - Called by the garbage collector on an object when garbage collection determines that there are no more references to the object. getClass() - Returns the runtime class of an object. hashCode() - Returns a hash code value for the object. toString() - Returns a string representation of the object. notify(), notifyAll(), and wait() - Play a part in synchronizing the activities of independently running threads in a program. | ||||
| ||||
| Ans. Overloading - Similar Signature but different definition , like function overloading. Overriding - Overriding the Definition of base class in the derived class. | ||||
| ||||
| Ans. The Spring container is able to autowire relationships between collaborating beans. This means that it is possible to automatically let Spring resolve collaborators (other beans) for your bean by inspecting the contents of the BeanFactory without using | ||||
| ||||
| Ans. Simplest implementation we can have is a List wherein we can place ordered words and hence can perform Binary Search. Other implementation with better search performance is to use HashMap with key as first character of the word and value as a LinkedList. Further level up, we can have linked Hashmaps like , hashmap { a ( key ) -> hashmap (key-aa , value (hashmap(key-aaa,value) b ( key ) -> hashmap (key-ba , value (hashmap(key-baa,value) .................................................................................... z( key ) -> hashmap (key-za , value (hashmap(key-zaa,value) } upto n levels ( where n is the average size of the word in dictionary. | ||||