bindhu solomon


{ City }
< Country > india
* Profession *
User No # 5760
Total Questions Posted # 0
Total Answers Posted # 24

Total Answers Posted for My Questions # 0
Total Views for My Questions # 0

Users Marked my Answers as Correct # 774
Users Marked my Answers as Wrong # 119
Answers / { bindhu solomon }

Question { 9106 }

explain the classification of exception and hoew to handle
the exceptions


Answer

there are two types of exceptions in java

1> checked exceptions

checked exceptions are also known as compile time
exceptions as they are identified during compile time of
the program. It is also known as Normal Exception.
Example: FileNotFoundException,ClassNotFoundException, etc..

2> Unchecked exceptions

Unchecked Exceptions are also known as runtime exceptions
as they are identified during the runtime of the program.
Example: ArithmeticException etc..

Is This Answer Correct ?    11 Yes 2 No

Question { Wipro, 13770 }

what is Assertion?


Answer

An assertion is a statement enables us to test our
assumptions about the program.

Each assertion contains a boolean expression that
our believe will be true when the assertion executes. If it
is not true, the system will throw an error.

Is This Answer Correct ?    36 Yes 8 No


Question { TCS, 15471 }

When does the compiler supply a default constructor for a
class?


Answer

If we do not define any constructors, the
compiler inserts an invisible zero parameter
constructor "behind the scenes".

Is This Answer Correct ?    24 Yes 0 No

Question { Ordain Solutions, 9973 }

How does serialization work


Answer

The class whose instances are to be serialized
should implement an interface Serializable. Then pass the
instances to the ObjectOutputStream which is connected to a
FileOutputStream. This will save the object to a file...
When an object ios serialized, all the included
objects are also serialized along with the original object.

Is This Answer Correct ?    4 Yes 2 No

Question { 7213 }

To what value is a variable of the Boolean type
automatically initialized?


Answer

false

Is This Answer Correct ?    10 Yes 0 No

Question { 7336 }

Which class should you use to obtain design information
about an object


Answer

The Class class is used to obtain information about an
object's design.

Is This Answer Correct ?    4 Yes 1 No

Question { CTS, 36375 }

Why we need to serialize the object


Answer

Whenever an object is to be sent over the network, and
moreover if the state of an object is to be saved, objects
need to be serialized...

Is This Answer Correct ?    63 Yes 2 No

Question { Wipro, 43891 }

can we have virtual functions in java?


Answer

In java, all methods are virtual functions by default. So
we can override a method in any subclasses .

Is This Answer Correct ?    123 Yes 24 No

Question { 9514 }

What is more advisable to create a thread, by implementing
a Runnable interface or by extending Thread class?


Answer

Creating a thread using implementing Runnable interface
are more advisable. Suppose we are creating a thread by
extending a thread class, we cannot extend any other class.
If we create a thread by implementing Runnable interface,
we can extend another class.

Is This Answer Correct ?    6 Yes 0 No

Prev    1    [2]