Java - Interview Questions and Answers for 'System' | Search Java Interview Question - javasearch.buggybread.com
Javasearch.buggybread.com
Share

Search Java Interview Questions


 2137 questions in repository.
 There are more than 200 unanswered questions.
Click here and help us by providing the answer.
Label / Company      Label / Company / Text

   



Interview Questions and Answers for 'System' - 101 question(s) found - Order By Newest

Very Very frequently asked. Among the first few questions in almost all interviews.Among Top 5 frequently asked questions. Frequently asked in Indian service companies (HCL,TCS,Infosys etc, Based on multiple feedback )
  Q1. Difference between == and .equals() ?Core Java
Anonymous
Ans. "equals" is the method of object class which is supposed to be overridden to check object equality, whereas "==" operator evaluate to see if the object handlers on the left and right are pointing to the same object in memory.

x.equals(y) means the references x and y are holding objects that are equal. x==y means that the references x and y have same object.

Sample code:

String x = new String("str");
String y = new String("str");

System.out.println(x == y); // prints false
System.out.println(x.equals(y)); // prints true

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   string comparison   string   object class   ==    equals   object equality     Ebay  Cerner  GuideWire  Expeditors Associate  Revature  SAIC  ValueLabs  Realty Redefined  Bank Of America  Capgemini  HCL Technologies  Goldman Sachs  Symmetric Corp  Backstop Solutions  Frontier  IQOR   Science  Vanguard  eClinicalWorks  Experticity  Blue Cross and Blue Shield of Kansas  ComTrade  Banja Luka  Overstock.com  Intrasoft International  IBM  Apex Systems  infoview technologies  Ebix  Cumulus Systems      basic        frequent

Try 6 Question(s) Test


Advanced level question. Frequently asked in High end product companies. Frequently asked in Cognizant ( Based on 2 feedbacks )
  Q2. Why is String immutable in Java ?Core Java
Anonymous
Ans. 1. String Pool - When a string is created and if it exists in the pool, the reference of the existing string will be returned instead of creating a new object. If string is not immutable, changing the string with one reference will lead to the wrong value for the other references.

Example -

String str1 = "String1";
String str2 = "String1"; // It doesn't create a new String and rather reuses the string literal from pool

// Now both str1 and str2 pointing to same string object in pool, changing str1 will change it for str2 too

2. To Cache its Hashcode - If string is not immutable, One can change its hashcode and hence it's not fit to be cached.

3. Security - String is widely used as parameter for many java classes, e.g. network connection, opening files, etc. Making it mutable might possess threats due to interception by the other code segment.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   oops   string   string class   immutable   advanced     Barclays  Jungo  Cloudera  Allston  Man Group  Prokarma  Optimus  Gamesys  ABS  TransPerfect  Fidelity  Deloitte  Zalando  Cognizant (CTS)  Zeta Interactive  SuccessFactors   EchoStar  InterGlobe Technologies  HCL Technologies  Intuit  JP Morgan  Optimus Information  Faichi Solutions  Blip  Adobe  Subex Limited  Remo Software  Allstate  IBM  Bizmatics  Bytecode Cyber Security  Calsoft Systems  IDS Infotech      expert        frequent

Try 4 Question(s) Test


Frequently asked to fresh graduates and less experienced developers. Among the first few questions in many interviews.
  Q3. What are the difference between composition and inheritance in Java?Core Java
Admin
info@buggybread.com
Ans. Composition - has-a relationship between classes.
Inheritance - is-a relationship between classes.

Composition - Composing object holds a reference to composing classes and hence relationship is loosely bound.
Inheritance - Derived object carries the base class definition in itself and hence its tightly bound.

Composition - Used in Dependency Injection
Inheritance - Used in Runtime Polymorphism

Composition - Single class objects can be composed within multiple classes.
Inheritance - Single class can only inherit 1 Class.

Composition - Its the relationship between objects.
Inheritance - Its the relationship between classes.

  Sample Code for inheritance

  Sample Code for composition

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   java concepts   inheritance   composition   inheritance vs composition     HCL Technologies  Tata Consultancy (TCS)  Infosys  Amazon  Source Intelligence  News UK  Starmount  MapQuest  SalesForce  Expedia  Deegit  JP Morgan  Canva  Todle  Yodle  Berkley Net  Help Scout  Partners HealthCare  Doximity  Commvault  Heroku  Starmount  Help.com  healthcare system  TU Kaiserslautern      basic        frequent

Try 5 Question(s) Test


Very frequently asked. Favorite question in Walk in Drive of many Indian service companies.
  Q4. Difference between TreeMap and HashMap ?Core Java
Anonymous
Ans. They are different the way their elements are stored in memory. TreeMap stores the Keys in order whereas HashMap stores the key value pairs randomly.

  Sample Code for treemap

  Sample Code for hashmap

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   collections   map   treemap   hashmap     Amber Road  CTS (Cognizant)  ION Trading  DataMetica  Accenture  The Advisory Board Company  BidGely  Infosys  Tata Consultancy (TCS)  HCL Technologies  Wipro  Booking.com  MakeMyTrip  Garena Online  Garmin  ION Trading  Accuity  Palantir Technologies  Books International  Wealthfront  Marin Software  Garmin  IBM  Global Logic  Fiserv  Cumulus Systems  CCTS  UST Global  Cumulus Systems      basic        frequent

Try 1 Question(s) Test


Frequently asked. Favorite question in Walk in Drive of many Indian service companies.
  Q5. What are the methods of Object Class ?Core Java
Anonymous
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.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   oops   object class     Capgemini  NIIT Technologies   Virtusa  Goldman Sachs  PwC  Citi  Expeditors  SoftFluent  LinkedIn  Amadeus  Navteq  PLC Systems  Axtria Associate  Netcracker Technology  Altisource      basic        frequent

Try 1 Question(s) Test


  Q6. Difference between SAX and DOM Parser ?Xml
Admin
info@buggybread.com
Ans. A DOM (Document Object Model) parser creates a tree structure in memory from an input document whereas A SAX (Simple API for XML) parser does not create any internal structure.

A SAX parser serves the client application always only with pieces of the document at any given time whereas A DOM parser always serves the client application with the entire document no matter how much is actually needed by the client.

A SAX parser, however, is much more space efficient in case of a big input document whereas DOM parser is rich in functionality.

Use a DOM Parser if you need to refer to different document areas before giving back the information. Use SAX is you just need unrelated nuclear information from different areas.

Xerces, Crimson are SAX Parsers whereas XercesDOM, SunDOM, OracleDOM are DOM parsers.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   xml   parsers   sax   dom parser   difference   architecture   technical lead   technical architect  markup language      First Advantage  Wellington Management  Chase Reference Data Distribution  System Soft Technologies  TD Bank Canada  JPMorgan Chase  Tata Consultancy (TCS)  PayPal  Citibank  Free Doctor Helpline  Wells Fargo  Huawei Technologies        frequent

Try 1 Question(s) Test


Very frequently asked. Favorite question in Walk in Drive of many Indian service companies.
  Q7. What is the difference between ArrayList and LinkedList ?Core Java
admin
info@buggybread.com
Ans. Underlying data structure for ArrayList is Array whereas LinkedList is the linked list and hence have following differences -

1. ArrayList needs continuous memory locations and hence need to be moved to a bigger space if new elements are to be added to a filled array which is not required for LinkedList.

2. Removal and Insertion at specific place in ArrayList requires moving all elements and hence leads to O(n) insertions and removal whereas its constant O(1) for LinkedList.

3. Random access using index in ArrayList is faster than LinkedList which requires traversing the complete list through references.

4. Though Linear Search takes Similar Time for both, Binary Search using LinkedList requires creating new Model called Binary Search Tree which is slower but offers constant time insertion and deletion.

5. For a set of integers you want to sort using quicksort, it's probably faster to use an array; for a set of large structures you want to sort using selection sort, a linked list will be faster.

  Sample Code for ArrayList

  Sample Code for LinkedList

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     collections   java   data structures   arraylist   linkedlist     Deutsche Bank  Overstock.com  HCL Technologies  Infosys  EBay  The Advisory Board Company  Accuity  JC Penney  Cerner  Chase  Amazon  Deloitte  Deegit  Tata Consultancy  Cognizant (CTS)  IBM  Accenture  Mindtree  ESRI  QwikCilver Solutions  TMC Bonds  GumGum  EMC  Yelp  Classteacher Learning System  FactSet  Simply Hired  SalesForce  Royall & Company  Indeed  eClinicalWorks  TravelClick  State Farm  Manhattan Associates  GoEuro  Veeva Systems  Ness Technologies  Marlabs  Rolta  Volante Technologies  Happiest Minds Technologies  Coviam  Velocify  zanox  SimplyHired  IDBI Intech  Wissen Infotech  Nike  OnDot  PexSupply  Pramati Technologies  Credit Agricole  Mastek  Six Dee Telecom  Accuity  Kellton Tech      Basic        frequent

Try 1 Question(s) Test


Very Frequently asked. Have been asked in HCL Technologies very frequently ( based on 2 feedback ). Among first few questions in many interviews.
  Q8. Differences between abstract class and interface ?Core Java
Admin
info@buggybread.com
Ans. Abstract classes can have both abstract methods ( method declarations ) as well as concrete methods ( inherited to the derived classes ) whereas Interfaces can only have abstract methods ( method declarations ).

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   classes   abstract class   interfaces     GlobalLogic  HCL Technologies  Tata Consultancy (TCS)  Infosys  Wipro  Mindtree  CapitalOne  Accenture  IBM India  Infoview Technologies  Salesforce  AT&T  United Health Group (UHG)  Verilogue  Amazon  Expeditors  Syntel  SalesForce  Cornerstone OnDemand  Expedia  OLA  NSF International  Copper Mobile  Think Future Technologies  MorphoTrust  Global Healthcare  Prodigious  Internet Brands  SciQuest  arvato Systems  iCIMS  Ideas2IT  virtusa polaris  Vitech Systems  Cognizant (CTS)      basic        frequent


Very Frequently asked to fresh graduates and less experienced. Favorite question in Walk in drives.
  Q9. Difference between Overloading and Overriding ?Core Java
Anonymous
Ans. Overloading - Similar Signature but different definition , like function overloading.

Overriding - Overriding the Definition of base class in the derived class.

  Sample Code for overloading

  Sample Code for overriding

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   oops   overloading   overriding   oops concepts   basic interview question     PC Technology  Cognizant (CTS)  Donlen   hybris Software  RedMane  Allerin Technologies  Gemalto  Allerin Technologies  HCL Technologies  Tata Consultancy (TCS)  Accenture India  Infosys Technologies  Polaris  United Healthcare India  IBM India  Xchanging  American Express  Antra  Flipp  Computer Sciences Corporation (CSC)  Garmin  NetSuite  Donlen  Hudsons Bay  Techlogix  SevOne  Synactive  Oodles Technologies  FDM Group  Marlabs  RedMane Technology  Faichi Solutions  TD  Tech Mahindra  Shutterfly  Luxoft  PC Technology  CCC Information Services  State Farm  Raja Software  Mastek  EPAM  Morgan Stanley  SummitWorks  Sony  Citibank  Emtec  LowerMyBills  Consilience  Xavor  AllState  FasTrak  AmTrust Financial  Walt Disney  Ultramain Systems  International Turnkey Systems  Knoldus Software  CA Technologies  Amdocs  FDM Group  Hybris  Fidelity  United Health Group (UHG)  Bluewhale Solutions  Pegasystems  Revature   Innoplexus  Vanguard  AptSource  Perficient  Grapecity  Subex  QuintilesIMS  NimbleUser  Expeditors Associate  Sapient  HR Cloud  Summitworks  Jabong.com  Kony Labs  Price Waterhouse Coopers (PWC)      basic        frequent

Try 1 Question(s) Test



Do you think these are the Best Java Frameworks ?

OpenXavaSPRING MVCApache StripesCheck everything
that is Best in Java

Click Here



  Q10. Difference between Vector and ArrayList ?Core Java
Anonymous
Ans. Vectors are synchronized whereas Array lists are not.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   basic interview question   vector   arraylist   collections   synchronization     Oracle  Lab49  Infosys  Wipro  Zoho  HCL Technologies  Tata Consultancy (CTS)  BirlaSoft  Emory  Xplana  British Telecom (BT)  Apex Systems  Capgemini  Accenture  3dplm Software Solution  AppKnox  eIntern  Landmark Information Group  ESystems  Orbitz Worldwide  HARMAN  Starmount  iConsultus  KARYA Technologies  Smart Chip  Cuelogic Technologies  Kronos  Trigent Software  Deloitte  ACI Worldwide  Unisys  Tavant Technologies  Referance data      basic        frequent


Advanced level question. Recently asked in few Indian service companies ( Based on 3 inputs )
 Q11. What are various types of Class loaders used by JVM ?Core Java
Admin
info@buggybread.com
Ans. Bootstrap - Loads JDK internal classes, java.* packages.

Extensions - Loads jar files from JDK extensions directory - usually lib/ext directory of the JRE

System - Loads classes from system classpath.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   jvm   memory management   class loaders   bootstrap   extensions   system  classloaders   advanced   technical lead   technical architect     Deloitte  Mindtree  Accenture  Synechron  IBM


Almost sure to be asked in every company using any Dependency Injection framework ( Spring, Guice etc )
  Q12. What is Dependency Injection or IOC ( Inversion of Control ) ?Design

Ans. It is a Design Pattern that facilitates loose coupling by sending the dependency information ( object references of dependent object ) while building the state of the object. Objects are designed in a manner where they receive instances of the objects from other pieces of code, instead of constructing them internally and hence provide better flexibility.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     design patterns   ioc ( Inversion of Control )  dependency injection     Nucleus Software Exports  HCL Technologies  Tata Consultancy (TCS)  HCL  Infosys  Cognizant (CTS)  Barclays  General Electric  Infosys Technologies  Elsevier  Sabre  ZapCom  Nike  Sogeti  CSG International  Lowes  DWS  Mitsui Bussan Logistics  Payment Processing Partners  Liquidnet  AmTrust Financial  VectorForm  Cybage  Vanderbilt University  Cigniti  Accenture  Ball Aerospace  GE Healthcare  1-800 Contacts  VinSolutions  Arrow Electronics  Monitise  Avenue Code  Thetus Corporation  Shodogg  Levi9  BuildLinks  Suyati Technologies  Kanerika Software  Alliance Inspection Management  Promega  Victorious  Zoll Data Systems  Parkmobile  PerceptiMed  Crate and Barrel  Carbonite  Concur  Codazen  GlobalLogic  AccuSoft  Attinad  Tillster  AppRiver  TrustPilot  Pearson  Kony  Art Technology Group  VeriSign  Accion Labs  IGS Energy  National Bankruptcy Services  RealPage  Green Dot  Indecomm Global  bebo Technologies  Open Solutions  Xoriant  NCR  Macmillan Cancer Support  NetSuite  Asynchrony Labs  DealDash  Vizio  Fiserv  Federal Reserve Bank of Minneapolis  Tinder  FICO  Trustwave      intermediate        frequent


  Q13. Does Java support Multiple Inheritance ?Core Java
Anonymous
Ans. Java doesn't support multiple inheritance. Interfaces does't facilitate inheritance and hence implementation of multiple interfaces doesn't make multiple inheritance.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   oop   oop concepts   inheritence   multiple inheritence   basic interview question     Credit Suisse  Sun Microsystems  VMware  NSEiT  Exterro  theScore  JP Morgan  Computrade Israel      basic        frequent

Try 1 Question(s) Test


Frequently asked to fresh graduates and less experienced developers.
 Q14. Explain multithreading in Java ?Core Java
Anonymous
Ans. 1. Multithreading provides better interaction with the user by distribution of task

2. Threads in Java appear to run concurrently, so it provides simulation for simultaneous activities.The processor runs each thread for a short time and switches among the threads to simulate sim-ultaneous execution (context-switching) and it make appears that each thread has its own processor.By using this feature, users can make it appear as if multiple tasks are occurring simultaneously when, in fact, each is running for only a brief time before the context is switched to the next thread.

3. We can do other things while waiting for slow I/O operations.In the java.iopackage, the class InputStreamhas a method, read(), that blocks until a byte is read from the stream or until an IOExceptionis thrown. The thread that executes this method cannot do anything elsewhile awaiting the arrival of another byte on the stream.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   threads   multi threading  concurrency   multithreading     Hamsini ECommerce   Cognizant (CTS)  Cumulus Systems  Cognizant (CTS)      intermediate        frequent

Try 1 Question(s) Test


Usually asked only to fresh graduates.
 Q15. What is the difference between time slicing and preemptive scheduling ?Operating System
Anonymous
Ans. In preemptive scheduling, highest priority task continues execution till it enters a not running state or a higher priority task comes into existence. In time slicing, the task continues its execution for a predefined period of time and reenters the pool of ready tasks.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     operating system   scheduling   threads   multi threading        rare


 Q16. What is meant by an "asynchronous event." Give some examples ?Operating System
Anonymous
Ans. An asynchronous event is one that occurs at an unpredictable time outside the control of the program that the CPU is running. It is not "synchronized" with the program.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     j2ee   internet   web application   asynchronus   asynchronus communication   architecture     Alten India


Frequently asked to fresh graduates.
  Q17. Difference between Process and Thread ?Operating System
Anonymous
Ans. Process is a program in execution whereas thread is a separate path of execution in a program.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   threads   multi threading   operating system   basic interview question     Walt Disney  Goldman Sachs  Nuance  Bank of America  Cogent Infotech  Sogeti  Siemens  Veritas  Vudu  One97 Communications  Riverbed Technology  TK20  MZ  Utopia  LogicMonitor  Lockheed Martin  Lab49  IGATE  Intel Corp  Verint Systems  Kronos  Amazon.com  Citrix  Persistent Systems      basic        frequent


Frequently asked to fresh graduates.
  Q18. What is a Deadlock ?Operating System
Anonymous
Ans. When two threads are waiting each other and cant precede the program is said to be deadlock.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   threads   multi threading   operating system   deadlock  concurrency     Lime Wire  Perfect Sense  QuantCast  Aequitas NEO Exchange  Akuna Capital  Juniper Networks  Casale Media  Netflix  NetApp  Apple  AIG  Cpart  SnapStream Media  Cumulus Systems  Wissen Infotech  HedgeServ Corp  KeyIdeas Infotech  Verint Systems  BlackBerry  EverQuote      basic        frequent


Frequently asked to fresh graduates.
 Q19. Explain Thread States ?Operating System
Admin
info@buggybread.com
Ans. Runnable - waiting for its turn to be picked for execution by the thread schedular based on thread priorities.

Running - The processor is actively executing the thread code. It runs until it becomes blocked, or voluntarily gives up its turn.

Waiting: A thread is in a blocked state while it waits for some external processing such as file I/O to finish.

Sleeping - Java threads are forcibly put to sleep (suspended) with Thread.sleep. they can resume using Thread.resume method.

Blocked on I/O - Will move to runnable after I/O condition like reading bytes of data etc changes.

Blocked on synchronization - Will move to Runnable when a lock is acquired.

Dead - The thread is finished working.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   threads   multi threading   scheduling   thread states   basic interview question     Cognizant (CTS)      basic        frequent

Try 2 Question(s) Test



Do you think these are the Best Java Frameworks ?

OpenXavaSPRING MVCApache StripesCheck everything
that is Best in Java

Click Here



Very frequently asked.Usually among first few questions.
  Q20. What is MVC ? Design
Anonymous
Ans. The Model/View/Controller pattern, a strategy for dividing responsibility in a GUI component.

The model is the data for the component.

The view is the visual presentation of the component on the screen.

The controller is responsible for reacting to events by changing the model.

According to the MVC pattern, these responsibilities should be handled by different objects.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     j2ee   mvc   mvc design pattern   design pattern   struts   spring   web application   web frameworks   ebay     HCL Technologies  Tata Consultancy (TCS)  Wipro  United Health Group (UHG)  Accenture  Fidelity  Fidelity Investments   Tieto  Walt Disney  Sharon Software Systems  Tech Mahindra  Amdocs  Deegit  Lexis Nexis  Elsevier      basic        frequent

Try 1 Question(s) Test


 Q21. What is race condition ?Operating System
Admin
info@buggybread.com
Ans. A source of possible errors in parallel programming, where one thread can cause an error in another thread by changing some aspect of the state of the program that the second thread is depending on (such as the value of variable).

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java.threads   multithreading   race condition   parallel programming   synchronization   ebay   concurrency     ISB Vietnam  NetSpend  Polycom  Cerner  NVIDIA  US Bank  Amadeus  McKesson  Hulu  Neelkanth Digital


 Q22. what is covariant return type? Core Java
Admin
info@buggybread.com
Ans. co-variant return type states that return type of overriding method can be subtype of the return type declared in method of superclass. it has been introduced since jdk 1.5

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   oops   inheritence   overriding   covariant return type   jdk5   advanced     Hewlett Packard (HP)  The Systems Group  Evergent      expert


Very frequently asked if being interviewed for hibernate. Frequently asked in Tata Consultancy (TCS) and Overstock.com
  Q23. Difference between load and get ?Hibernate
Admin
info@buggybread.com
Ans. If id doesnt exist in the DB load throws an exception whereas get returns null in that case.get makes the call to DB immediately whereas load makes the call to proxy.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     hibernate     Overstock.com  Nagarro  Anthem  Tata Consultancy (TCS)  Nucleus Software Exports  CDK Global  Dell  Capgemini  Persistent Systems  HCL Technologies  Nagarro  Sears  CDK Global  Oracle  Nucleus Software Exports  CACI International      basic        frequent


 Q24. Explain System.out.println ?Core Java2016-11-25 09:37:08

Ans. System is a class within java.lang package that contains several useful class fields and methods. It cannot be instantiated and hence can use only statically.even in this case this has been used statically i.e with class name itself and without creating an instance.

out is the static reference of Printstream declared as following in the System Class -

public final static PrintStream out = null;

println is the method of PrintStream class.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     System class  Streams  Input Output  println      basic        frequent


Frequently asked in Tech Mahindra ( Based on 3 inputs )
  Q25. What is the difference between List, Set and Map ?Core Java
Anonymous
Ans. List - Members are stored in sequence in memory and can be accessed through index.
Set - There is no relevance of sequence and index. Sets doesn't contain duplicates whereas multiset can have duplicates.
Map - Contains Key , Value pairs.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   collections   list   set   map     Cognizant (CTS)  Ebay   Infosys   HCL Technologies   Tech Mahindra  Cumulus Systems  Mindteck      basic        frequent

Try 1 Question(s) Test


Frequently asked at HCL Technologies ( Based on 3 feedback )
  Q26. Difference between Checked and Unchecked exceptions ?Core Java
Anonymous
Ans. Checked exceptions are the exceptions for which compiler throws an errors if they are not checked whereas unchecked exceptions are caught during run time only and hence can't be checked.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   exceptions   checked exceptions   unchecked exceptions   exception handling   basic interview question     Verilogue  F5 Network  Pegasystems  PegaSystems  SAP  Ciber  Conde Nast  Pramati Technologies  IBM  JP Morgan  HCL Technologies  Tata Consultancy (TCS)  Cognizant (CTS)  Cogent Infotech  MarketAxess  defense group  NETS INTERNATIONAL  Accenture  Integra Micro  ColdLight Solutions  Endeavor  Deloitte  Infosys      basic        frequent

Try 1 Question(s) Test


Frequently asked to fresh graduates.
 Q27. What are the difference between Threads and Processes ?Operating System
Anonymous
Ans. 1. when an OS wants to start running program it creates new process means a process is a program that is currently executing and every process has at least one thread running within it.
2). A thread is a path of code execution in the program, which has its own local variables, program counter(pointer to current execution being executed) and lifetime.
3. When the JavaVirtual Machine (JavaVM, or just VM) is started by the operating system, a new process is created. Within that process, many threads can be created.
4. Consider an example : when you open Microsoft word in your OS and you check your task manger then you can see this running program as a process. now when you write something in opened word document, then it performs more than one work at same time like it checks for the correct spelling, it formats the word you enter , so within that process ( word) , due to different path execution(thread) all different works are done at same time.
5. Within a process , every thread has independent path of execution but there may be situation where two threads can interfere with each other then concurrency and deadlock come is picture.
6. like two process can communicate ( ex:u open an word document and file explorer and on word document you drag and drop another another file from file explorer), same way two threads can also communicate with each other and communication with two threads is relatively low.
7. Every thread in java is created and controlled by unique object of java.lang.Thread class.
8. prior to jdk 1.5, there were lack in support of asynchronous programming in java, so in that case it was considered that thread makes the runtime environment asynchronous and allow different task to perform concurrently.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   operating system   threads   processes     Ciena  Walt Disney        frequent


Usually asked only to fresh graduates.
 Q28. Why threads block or enters to waiting state on I/O?Operating System
Anonymous
Ans. Threads enters to waiting state or block on I/O because other threads can execute while the I/O operations are performed.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   threads   multithreading   scheduling   operating system


Frequently asked to fresh graduates.
 Q29. What is the difference between yield() and sleep()?Operating System
Anonymous
Ans. When a object invokes yield() it returns to ready state. But when an object invokes sleep() method enters to not ready state.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   threads   multi threading   yield   sleep   scheduling   operating system     RedMane  Levi9  RedMane Technology  Time      basic        frequent



Do you think these are the Best Java Frameworks ?

OpenXavaSPRING MVCApache StripesCheck everything
that is Best in Java

Click Here



Usually asked only to fresh graduates.
 Q30. What is the initial state of a thread when it is created and started?
Anonymous
Ans. Ready state.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     operating system   threads   multi threading   java   thread states     Cognizant (CTS)      basic        frequent


 Q31. What is suspend() method used for ?
Admin
info@buggybread.com
Ans. suspend() method is used to suspend the execution of a thread for a period of time. We can then restart the thread by using resume() method.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   threads   multi threading   operating system   synchronization      basic        rare


Usually asked only to fresh graduates.
 Q32. Difference between suspend() and stop() ?
admin
info@buggybread.com
Ans. Suspend method is used to suspend thread which can be restarted by using resume() method. stop() is used to stop the thread, it cannot be restarted again.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   threads   multi threading   operating system   synchronization   suspend   stop      basic        rare


 Q33. What is the difference between System.console.write and System.out.println ?
Admin
info@buggybread.com
Ans. System.console() returns null if your application is not run in a terminal (though you can handle this in your application)System.console() provides methods for reading password without echoing charactersSystem.out and System.err use the default platform encoding, while the Console class output methods use the console encoding

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   system class   system.out.println   system.console.write   input output   java6      intermediate        rare


Usually asked only to fresh graduates and less experienced developers.
  Q34. What is a daemon thread? Give an Example ?
Admin
info@buggybread.com
Ans. These are threads that normally run at a low priority and provide a basic service to a program or programs when activity on a machine is reduced. garbage collector thread is daemon thread.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   threads   multi threading   operating system   daemon thread   garbage collection     Finnet  ServiceNow  MarketAxess Holdings  JP Morgan  Utopia  Samsung  CGI Group  Auriel Technologies      intermediate        frequent

Try 2 Question(s) Test


Frequently asked in CTS ( Based on 2 feedback )
  Q35. What is the difference between comparable and comparator in java.util pkg?Core Java
Admin
info@buggybread.com
Ans. Comparable interface is used for single sequence sorting i.e.sorting the objects based on single data member where as comparator interface is used to sort the object based on multiple data members.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   java.util   comparable   comparator   collections     Verilogue  Accenture  Varian Medical Systems  L&T Infotech  Oracle  eIntern  Happiest Minds Technologies  HCL Technologies  Cognizant (CTS)  Cerner  Coviam  EdgeVerve Systems  Virtusa Polaris  Trimax IT Infrastructure & Services      basic        frequent


 Q36. What are the phases of the JSP life cycle ?Java EE
Admin
info@buggybread.com
Ans. Translation of JSP PageCompilation of JSP PageClassloading (class file is loaded by the classloader)Instantiation (Object of the Generated Servlet is created).Initialization ( jspInit() method is invoked by the container).Reqeust processing ( _jspService() method is invoked by the container).Destroy ( jspDestroy() method is invoked by the container).

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     j2ee   servlets   servelets   web application   jsp   jsp life cycle   mindtree     Span Infotech  PTC  Cybage  iNautix Technologies  TechAspect  Brillio  Modus Information Systems  SAG Infotech   TechProcess Payment Services


 Q37. What is the difference between System.out ,System.err and System.in?
Admin
info@buggybread.com
Ans. System.out and System.err both represent the monitor by default and hence can be used to send data or results to the monitor. But System.out is used to display normal messages and results whereas System.err is used to display error messages and System.in represents InputStream object, which by default represents standard input device, i.e., keyboard.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   io   system.out   system.err   system.in   difference between   advanced   basic interview question


 Q38. What are use cases?Process
Admin
info@buggybread.com
Ans. It is part of the analysis of a program and describes a situation that a program might encounter and what behavior the program should exhibit in that circumstance.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     use cases   design   high level design   testing   test driven development   software system analyst   project lead      basic        frequent


 Q39. What is the purpose of the System class?Core Java
Admin
info@buggybread.com
Ans. The purpose of the System class is to provide access to system resources.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   system   io   file io



Do you think these are the Best Java Frameworks ?

OpenXavaSPRING MVCApache StripesCheck everything
that is Best in Java

Click Here



 Q40. Will finally be called always if all code has been kept in try block ?Core Java
Admin
info@buggybread.com
Ans. The only time finally won't be called is if you call System.exit() or if the JVM crashes first.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   exceptions   exception handling   try   catch   finally   system   system.exit


  Q41. Write a Program to check if 2 strings are Anagrams ?Core Java2016-11-30 20:52:37

Ans. public void checkIfAnagram(String str1,String str2){
boolean anagram = true;
for(char c:str1.toCharArray()){
if(!str2.contains(String.valueOf(c))){
System.out.println("Strings are Anagrams");
anagram = false;
}

if(anagram == true){
System.out.println("Strings are not Anagrams");
}
}
}

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve      check if 2 strings are Anagrams     Amazon  DataMetica  Hewlett Packard (HP)  Opera Solutions  AirWatch  Booking.com  JP Morgan  Verdantis  AppDynamics  QSI Healthcare  Vistaar Technologies  Maventic  5AM Solutions  Rare Mile Technologies  Shutterfly  Fiberlink  Veeva Systems  Flipkart  eHarmony  Splunk  Zoho  Betterment  WisdmLabs  Adap.tv  Spotify  Yahoo  Wissen Infotech  GlobalLogic      basic        frequent


 Q42. Difference between PATH and CLASSPATH ?Operating System
Admin
info@buggybread.com
Ans. PATH is the variable that holds the directories for the OS to look for executables. CLASSPATH is the variable that holds the directories for JVM to look for .class files ( Byte Code ).

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   path   classpath   byte code   jvm   basic interview question     CapitalOne  MathWorks  eG Innovations      intermediate        rare


 Q43. Difference between Class Path and Build Path ?Core Java2017-11-05 16:22:58

 This question was recently asked at 'IBIS System'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve          IBIS System


Very Frequently asked. Favorite question in walkins and telephonic interviews. Usually among first few questions. Asked in different variants. Must know for intermediate and expert professionals.Among Top 10 frequently asked questions.
  Q44. What is rule regarding overriding equals and hashCode method ?Core Java
Admin
info@buggybread.com
Ans. A Class must override the hashCode method if its overriding the equals method.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   collections   hashcode  hash code   equals   collections     Cognizant (CTS)  CapitalOne  Tata Consultancy (TCS)  HCL Technologies  Deloitte  Wipro  Infosys  Sabre  Sophos   Tieto  Addteq  Priceline.com  Cisco Systems  Visa Inc  Vibrant Media  Audience Science  GT Nexus  OpenCrowd  Instinet  Kronos  Elsevier  IMC Financial  LG Mobile  Dun & Bradstreet  WBUT  codecentric  Satmetrix  Interactive Brokers  Roposo  SecureView  Azuga  Envestnet  Criteo  Skillz  MobileIron  Walmart  R Systems  Overstock.com  Verilogue  Goldstone Technologies  FatWire  LinkedIn  Southwest Airlines      intermediate        frequent

Try 1 Question(s) Test


 Q45. What is a ConcurrentHashMap ?Core Java
Admin
info@buggybread.com
Ans. ConcurrentHashMap is a hashMap that allows concurrent modifications from multiple threads as there can be multiple locks on the same hashmap.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   collections   hashmap   map   concurrenthashmap   concurrenthashmap  concurrency   general electric   ge     Cognizant (CTS)  Synechron  General Electric  MakeMyTrip.com  Nomura Securities  Xpanxion  Royal Bank of Scotland (RBS)  ProKarma  Talentica  Citi  EdgeVerve Systems  Six Dee Telecom  ReqRoute  Qumulo  Goldman Sachs  HSBC Holdings  AlertMe.com  BlackRock  Helpchat  Bally Technologies  Hubzu  Xpanxion  Coromandel Infotech  Paytm  YuMe  InfoGain  Markit  Wells Fargo  Geometric  Acloudzyn Technologies  Roposo        rare


  Q46. What is lazy fetching in Hibernate ?Hibernate
Admin
info@buggybread.com
Ans. Lazy fetching is the technique of not loading the child objects when parent objects are loaded. By default Hibernate does not load child objects. One can specify whether to load them or not while doing the association.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     hibernate   lazy fetching   architecture     Aldo  Rent the Runway  Veteran Corps  United Health Group (UHG)  Medgate  Prokarma  Mars Telecom Systems  Dun & Bradstreet  Kumaran Systems  Tavant Technologies  CaseNet        frequent

Try 2 Question(s) Test


 Q47. Should we create system software ( e.g Operating system ) in Java ?Core Java
Admin
info@buggybread.com
Ans. No, Java runs on a virtual machine called JVM and hence doesn't embed well with the underlying hardware. Though we can create a platform independent system software but that would be really slow and that's what we would never need.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   system software java   jvm   yes-no   yes no   java operating system   architecture


 Q48. Give an Example for Builder Pattern ?Core Java
Admin
info@buggybread.com
Ans. String str = new StringBuilder().append("Buggy").append("Bread").toString();

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   builder pattern   design pattern   stringbuilder   string     Power System Consultants (PSC)  Xactly Corp  BetterCloud

Try 1 Question(s) Test


 Q49. Which Software Development methodology is being used in your current Job ?Process
Admin
info@buggybread.com
Ans. We are using Agile methodology. I attend daily stand up where the development leads takes the status of assigned stories, achievements, any bottlenecks or challenges. We follow iteration of 2 weeks.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     sdlc   agile methodology   software system analyst   software developer interview   development lead   project lead interview



Do you think these are the Best Java Frameworks ?

OpenXavaSPRING MVCApache StripesCheck everything
that is Best in Java

Click Here



 Q50. Which UML diagrams you usually use for design ?Design
Admin
info@buggybread.com
Ans. Use Case Diagram, Component Diagram for High level Design and Class Diagram , Sequence Diagram for low level design.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     software system analyst   development lead   project lead   technical lead   technical architect      expert        frequent


 Q51. How do you coordinate and communicate with the team developers ?Process
Admin
info@buggybread.com
Ans. We as a team of developers , testers , analyst , lead and architect sit close to each other. Most of the time I would just jump to their seat and talk to them ( if required ). We have daily stand up where we discuss things that needs team attention.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     system software analyst   technical architect   technical lead   project lead   development lead


 Q52. What is your role in current position ?
Admin
info@buggybread.com
Ans. I am working as a Software System Analyst that specializes in understanding Business Requirements, Analyzing them , Performs Cost / Benefit analysis, Make suggestions to business , translate the business requirements into technical requirements, Discuss their feasibility with the technical team, performs sizing in coordination with developers and prepare high level design document.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     system analyst   software system analyst   software business analyst


 Q53. What kind of software architecture your organization follow ?Design
Admin
info@buggybread.com
Ans. We have multi tier architecture with multiple layers , We have series of web servers and applications in application tier, infrastructure libraries at middle tier and Database servers at the lower tier. We are using Oracle as Database, ESB ( Enterprise service Bus ) for asynchronous communication and Rest Web Services.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     software system analyst   development lead   project lead   technical lead   technical architect


 Q54. Do you talk to testers ?
Admin
info@buggybread.com
Ans. Yes, usually I would talk to them to make sure that we are on same page in terms on understanding the business requirement.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     software system analyst   business analyst


 Q55. What you would do if you realize that business requirement is not technically feasible ?
Admin
info@buggybread.com
Ans. I would first try to make sure that I am correct in that understanding. Will talk to developers and architects to understand the technical challenges to accomplish it. Once I am done with my ground work, Will schedule a meeting with business stake holders. Will gather required evidences and will present the challenges to Business.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     software system analyst   business analyst


 Q56. Which version control system you are using in your current project ?Tools
Admin
info@buggybread.com
Ans. We are using SVN and Git Hub.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     build management   version control systems   configuration management   configuration manager   version control manager     IBM


 Q57. What is Nagios ?
Admin
info@buggybread.com
Ans. Nagios is open source system , network and infrastructure monitoring software application. It alerts the user if anything goes wrong. Nagios is widely used as monitoring tool for enterprise applications.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     production support   application support   nagios   system monitoring


 Q58. Write code explaining use of Scanner class ?
Admin
info@buggybread.com
Ans. Scanner sc = new Scanner(System.in);
int i = sc.nextInt();

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   scanner   io   console io   scanner   System.in


 Q59. What is the difference between out.println(a+b); and out.println (a+" " +b); in Java? with a=2 and b=1Core Java
Admin
info@buggybread.com
Ans. First will give the ouput as 3 and the second will give output as 2 1

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   system.out.println   coding



Do you think these are the Best Java Frameworks ?

OpenXavaSPRING MVCApache StripesCheck everything
that is Best in Java

Click Here



 Q60. How do you monitor the server resources if inadvertently high traffic is reported ?
Admin
info@buggybread.com
Ans. We use SAR command for that purpose. We also have GUI system monitoring tool to keep real time check of requests, load and memory usage.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     server monitoring   production support   servers   website traffic   system monitoring   sar   application support


 Q61. What are the fail safe systems ?Operating System2016-06-09 09:29:43

Ans. Fail Safe systems are tolerant systems that continue processing even if they sense any problem. the objective here is to continue with the processing even if there are some problems instead of completely shutting it down. Example could be to catch an exception and still letting it complete with partial results.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     fail safe systems   system design   exception handling     Verilogue


 Q62. What are the advantages of using distributed database management system ?Database2016-11-30 16:05:24

Ans. Reliability and Continuity if some of the sites goes down.Easy Scaling up and Down as sites can be added or removed without impacting business continuity.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     dbms  database management system  distributed database management system     Elsevier


Frequently asked in face to face interviews.
  Q63. Write a program to print fibonacci series.Core Java

Ans. int count = 15;
int[] fibonacci = new int[count];
fibonacci[0] = 0;
fibonacci[1] = 1;
for(int x=2; x < count; x++){
fibonacci[x] = fibonacci[x-1] + fibonacci[x-2];
}

for(int x=0; x< count; x++){
System.out.print(fibonacci[x] + " ");
}

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     ebay   fibonacci series     Manvish eTech  Belvedere Trading  King UK  FinaTel  Goldman Sachs  Enlighten Software  Misys  Mahindra Comviva  ZapCom  Nucleus Software Exports  Enlighten  Sears  Mahindra Satyam  Insperity  General Motors  AVIS e Solutions  Paddy Power Betfair  TurningCloud  Polestar Solutions  BlueWhale Solutions  CitiusTech  Zuhlke  Comcast  KGFSL  Quickr  Paramatrix Technologies  CalSoft  Ancestry.com  OnMobile Global  NBCUniversal  Inventum Technologies  Hughes Systique  Flextronics  Geometric Soft  Check Point Software Technologies  ZapLabs  Indecomm Global Services  HTC Global  Quovantis Technologies  Mobiloitte  Riktam Technologies  DMX Technologies  Mojo Networks  Tata Elxsi  Ciena  ServiceNow  EverBridge  LendingClub  Virtusa Polaris  West Corporation  Ebay  Walmart  HomeAway  AllClear ID  Quinnox Software  Acquity Group  Cadence Design Systems  SmartPrix  Leidos  Zoho  Varian Medical Systems  HealthSparq      basic        frequent


 Q64. What is use of Revert in SVN?Tools

Ans. Revert your local changes.

There are 2 types of reverts -

1) Local Revert: It will delete all changes from files which you made after updates and before commit.
2) Repo Revert: Upload the changes to previous Repo.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     svn  subversion  version control system  configuration management     Mphasis  Oakton


 Q65. What are the fail fast systems ?2016-06-09 09:31:27

Ans. Fail fast systems are intolerant systems that fails at the first instance of smelling any problem. The objective here is to break the system instead of continuing with the possibly flawed processing. Example could be breaking the processing upon an exception.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     fail fast systems   system design     Verilogue


 Q66. What are the two main components of Hadoop System ?BigData2016-10-17 09:56:41

Ans. Distributed file system and Map Reduce system.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     hadoop  bigdata  hadoop system components        frequent


 Q67. What is the use of Combiners ?BigData2016-10-17 10:03:41

Ans. Combiners are used to increase the efficiency of a Map Reduce program. They are used to aggregate intermediate map output locally on individual mapper outputs. Combiners can help you reduce the amount of data that needs to be transferred across to the reducers.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     Hadoop Systems  BigData   hadoop combiners     Barclays


Frequently asked for Lead and Architect positions. Recently asked in many US companies.
  Q68. What are Anti Patterns ?Design2016-07-14 14:21:11

Ans. Anti-pattern is simply the creation of a pattern in your coding that negatively affects your code i.e the Negatives surpasses the positives.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     anti patterns  design patterns     JP Morgan  Zoftech Systems  Winter Court Consulting  Tripsta  Travelplanet24  The Big Game Hunter  Pardot  Randstad  Addison        frequent


 Q69. What are Node / Slaves in Jenkins ?Jenkins2016-07-20 14:45:59

Ans. Slaves are computers that are set up to build projects for a master.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     jenkins  build management system



Do you think these are the Best Java Frameworks ?

OpenXavaSPRING MVCApache StripesCheck everything
that is Best in Java

Click Here



 Q70. What is System.in in Java ?Core Java2016-09-02 08:24:11

Ans. It is an InputSream which is usually connected to the keyboard input of console program.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     System.in  Input Stream  Input Output


 Q71. Difference between System.out.printf and System.out.println ?Core Java2016-11-25 09:38:09

Ans. println prints an additional end of line whereas printf doesnt.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     System class  Streams  Input Output  println  printf


 Q72. Which method of String class is used to convert Boolean to String ?Core Java2016-12-17 11:00:44

Ans. toString() is an overloaded method of String class that is used to convert many data types to String, Boolean being one of them.

toString(Boolean bool)

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     String  String class  Boolean     Techurate Systems      Basic


  Q73. What is an exception and exception handling in Java ?Core Java2017-01-09 13:01:40

Ans. An Exception in java is the occurrence during computation that is anomalous and is not expected.

Exception handling is the mechanism which is used to handle such situations.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     exception handling     EPAM  Deloitte  Choice Hotels  Future Group  Cognizant (CTS)  Wipro  Infosys  HCL Technologies  Accenture  Amdocs  IBM  Ultramain Systems      basic        frequent


 Q74. Which environment variables do we need to set in order to run Java programs?Core Java2017-01-12 10:55:08

Ans. PATH, CLASSPATH and JAVA_HOME

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     environment variables  path  classpath  java_home     QUADRATIC SYSTEMS  Computer sciences corporation (csc)  HCL Technologies      basic        frequent


 Q75. Can an application have multiple main methods within different classes ? If yes, How will the app decide which one to be executed ?Core Java2017-01-12 10:56:40

Ans. Yes we can have a main method with string[] argument in every class of an application. When we execute an app we specify the starting point i.e the class that will get the control first and hence main method of that class gets executed.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     main method     HCL Technologies  Aspire Systems  SapientNitro


 Q76. Have you done any sort of automation in your system monitoring tasks ?Support2017-01-16 10:12:24

Ans. Yes we have created System as well as Log monitoring scripts to keep track of exceptions. We are also using a tool that will inform the stake holders if an exceptional event occurs with the system.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     production support  system monitoring  log monitoring


 Q77. What are your responsibilities after the problem ticket has been closed ?Support2017-01-16 10:14:07

Ans. We inform the stakeholders regarding the resolution and steps taken for it. We updated the ticket notes and link it with the master / related tickets. RCA is done for the high priority and critical issues and a report is submitted.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     production support  system support


 Q78. why should one we use 32 bit system instead of 64 bit?Operating System2017-03-27 08:52:35

Ans. Performance of a system doesn't solely rely on size of processor or it's communication size. It should also be compatible with other resources like memory, storage etc. Moreover it makes no sense to have 64 bit systems when there is hardly any software than can run on 64 bit system.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     


 Q79. Write a Program to print factorial of a number using recursionCore Java2017-01-29 17:47:20

Ans. public class BuggyBread {
public static void main(String args[]) {
System.out.println(factorial(5));
}

private static int factorial(int number){
if(number == 1){
return 1;
} else {
return number * factorial(number - 1);
}
}
}

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     recursion     PrimeFocus Technologies  Aavanor System  Mobicip  CMSS Private Limited  Intrepid Pursuits  Indus Valley Partners  Sunquest Information Systems  Linchpin  Riverbed Technology  Knoldus Software  Sopra Steria  Sunquest Information Systems  OpenBet  DMX Technologies  Whitesnow Software Consultancy  NextSphere  Clearwater Analytics  Obelisk Infosystems  iNautix Technologies  Andesa Services  NextSphere  MobileIron  Wolfram Research  Spillman Technologies



Do you think these are the Best Java Frameworks ?

OpenXavaSPRING MVCApache StripesCheck everything
that is Best in Java

Click Here



 Q80. What is a Webdriver ?Testing2017-02-02 08:25:41

Ans. Selenium WebDriver is a tool for automating web application testing.It helps in replicating the manual tester behavior like keyboard entry, mouse events etc and then matching the output against the expected.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     selenium  webdriver     Global Software Resources  FICO Software  Walt Disney  Softcrylic  Sky  23andMe  Endurance Group  CitiusTech  Hitachi Consulting  Crest Premedia  LivingSocial  TEKSystems  Jabong.com  Think Future Technologies  Dollar Shave Club  Zendesk  Five9  Aptify  Symphony Teleca  Collabera  Xpanxion  Fourth Technologies  Freedom Financial  Aurigo Software Technologies  Forte Group  Wipro  Infosys  Pearson  Overstock  Elsevier  Capgemini  Cognizant (CTS)  Tech Mahindra  OLA Software  Mphasis  GrayLocus  Bhavna


 Q81. Difference between Singleton and Factory Design Pattern ?Design2017-02-02 11:24:01

Ans. Both are creational design patterns but singleton facilitates in creation and reuse of single object whereas Factory deals with creation of multiple objects.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     Design pattern  singleton  factory  singleton vs factory     Jabong.com  Intuit  Kumaran Systems  BirlaSoft


 Q82. Describe Marketing subsystem and What WCS components are part of this system ?IBM WCS2017-02-02 15:05:24

Ans. The Marketing subsystem is a component of the WebSphere Commerce Server, and provides numerous marketing concepts to your site, designed to increase brand awareness, and to attract and retain customers. Components of the marketing subsystem provide functionality to create marketing campaigns, including customer segments and advertising; and e-mail activities.

Various components are -

1. Promotions
2. Auctions
3. eSpots
4. e Mail Campaigns
5. Hubs and Extended sites for affiliates

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     marketing subsystem


 Q83. Describe Catalog subsystem and the tables used in WCS for managing this ?IBM WCS2017-02-02 15:08:39

Ans. The catalog subsystem or Catalog Management provides online catalog navigation, partitioning, categorization, and associations. In addition, the catalog subsystem includes support for personalized interest lists and custom catalog display pages. The catalog subsystem contains all logic and data relevant to an online catalog, including catalog groups (or categories), catalog entries, and any associations or relationships among them.

Tables used for Catalog subsystem

1. CATENTRY
2. CATENTREL

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     catalog subsystem


 Q84. What is ACL ?Operating System2017-03-01 09:45:12

Ans. Access Control List or ACL is the list of permissions attached to an object in the File System.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     acl  file system  file security  object security  operating system


 Q85. Difference between Mutex and Semaphore? Operating System2017-03-03 14:24:07

 This question was recently asked at 'Veritas'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     Mutex vs Semaphore     Veritas


 Q86. Difference between Virtual Memory and Demand Paging?Operating System2017-03-03 14:24:34

 This question was recently asked at 'Veritas'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     Virtual Memory vs Demand Paging     Veritas


 Q87. Explain process life cycle.Operating System2017-03-03 14:25:20

 This question was recently asked at 'Veritas'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve          Veritas


 Q88. What is an Operating system or OS ?Operating System2017-03-03 14:26:14

 This question was recently asked at 'Veritas'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve          Veritas


 Q89. What is thrashing?Operating System2017-03-03 14:26:30

 This question was recently asked at 'Veritas'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve          Veritas



Do you think these are the Best Java Frameworks ?

OpenXavaSPRING MVCApache StripesCheck everything
that is Best in Java

Click Here



 Q90. What is Priority inversion ?Operating System2017-03-08 12:19:40

Ans. Priority inversion is a problematic scenario in scheduling in which a high priority task is indirectly preempted by a lower priority task effectively inverting the relative priorities of the two tasks.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve          MathWorks  Qualcomm  Juniper Networks  Sling Media  ST Microelectronics


 Q91. What is JVM ?Core Java2017-04-07 10:16:18

 This question was recently asked at 'ABS,Trimax IT Infrastructure & Services,Cumulus Systems'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     memory management  jvm     ABS  Trimax IT Infrastructure & Services  Cumulus Systems      basic        frequent


 Q92. Write a class and override the equals and hashcode method ?Core Java2017-05-03 15:32:05

 This question was recently asked at 'Vitech Systems'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve          Vitech Systems


 Q93. What are the four situations that are required for deadlock to happen ?Operating System2017-05-07 16:38:57

Ans. mutual exclusion i.e the resource is not shareable and hence a process should have exclusive access to it at a particular time

Hold and Wait i.e the process doesn't release all existing resources held by it before requesting for another one.

No preemption i.e noone can forcefully release a resource held by another process and the process should voluntarily release the resource held by it.

Circular Wait - For ex, P1 is waiting on resource to be released by P2, P2 is waiting on resource to be released by P3 and P3 is waiting on the resource to be released by P1

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     deadlock  process


 Q94. What is Livelock in relation to deadlock ?Operating System2017-05-07 16:40:25

Ans. Livelock is when two threads or processes get deadlocked because they try to perform the same action to come out of a potential deadlock.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     livelock  deadlock]


 Q95. What is the difference between CountingSemaphore and a CountDownLatch?Operating System2017-05-07 19:31:17

 This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     CountingSemaphore  CountDownLatch


 Q96. What is a host file ?Operating System2017-05-24 13:08:27

Ans. It's an operating system file that maps IP address to host names. The hosts file assists the OS in addressing networked components and serves the function of translating human friendly hostnames into numeric protocol addresses, called IP addresses, that identify and locate a host in an IP network.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     host file  operating system     Wayfair


 Q97. What are the examples of immutable objects in Java ?Core Java2017-05-29 08:35:00

Ans. Following Classes in Java SE creates immutable objects

String class
Wrapper Classes like Integer, Float etc.
StackTraceElement
Most Enum classes
File Class
Locale Class

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     immutable objects  immutable     Persistent Systems      Basic        frequent


 Q98. Can you give real time examples of thread or where thread are actually used ?Core Java2017-05-29 08:35:42

 This question was recently asked at 'Persistent Systems'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     threads  multithreading     Persistent Systems


 Q99. Solve the producer and consumer problemOperating System2017-06-15 08:18:53

 This question was recently asked at 'Dell'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     producer consumer problem  multi-process synchronization problem     Dell


 Q100. What is out in System.out.println ?Core Java
a. out is static inner class
b. out is the reference for static inner class object
c. out is the static reference to OutputStream object
d. out is the static reference to PrintStream object

Ans.d. out is the static reference to PrintStream object



Subscribe to Java News and Posts. Get latest updates and posts on Java from Buggybread.com
Enter your email address:
Delivered by FeedBurner



comments powered by Disqus
 

Help us and Others Improve. Please let us know the questions asked in any of your previous interview.

Any input from you will be highly appreciated and It will unlock the application for 10 more requests.

Company Name:
Questions Asked:
         

X Close this

22 person from Sunnyvale are looking for questions for 'System'. Connect with them to better prepare for your interview.Click here and post a message

Cumulus systems: Interview wasnt easy as I wasnt much ... Anonymous

Cumulus systems: They asked me to write program for ... Vijay

X Close this

Help Us Improve.
Please share your
interview experience.

Company Name:   


Questions Asked: