Searching for "%"

Q:

Tell us about a time when you missed a significant deadline

Answer

Tell us about a time when you missed a deadline.


(or)


Let's discuss a time when you missed a significant deadline.


If you answer something like "You never missed a deadline". Most interviewers will immediately conclude you are not experienced and may also feel you are lying. 


Approach - It is absolutely necessary to accept that you have missed a deadline and give reasons how you resolved and what you learned from it. This will demonstrate your experience.


You could say in one of the first projects earlier in your career you missed an important deadline and made the boss very upset. It was a great learning experience and after doing some introspection, you realized, you could have done better planning, prioritization and communication. Now, you use special tools, processes and methods to address these issues. Now your team, colleagues and management are always up to date so no surprises arise on meeting deadlines. 


Below are few things you may emphasize on in your response...


Effective planning


Procedural Improvements


Better Prioritization


Open communication


Better Status reporting

Report Error

View answer Workspace Report Error Discuss

Q:

How is final different from finally and finalize()?

Answer final is a modifier which can be applied to a class or a method or a variable. final class can't be inherited, final method can't be overridden and final variable can't be changed.

finally is an exception handling code section which gets executed whether an exception is raised or not by the try block code segment.

finalize() is a method of Object class which will be executed by the JVM just before garbage collecting object to give a final chance for resource releasing activity.
Report Error

View answer Workspace Report Error Discuss

Subject: Java

Q:

Can you give few examples of final classes defined in Java API?

Answer

java.lang.String,  java.lang.Math are final classes.

Report Error

View answer Workspace Report Error Discuss

Subject: Java

Q:

When will you define a method as static?

Answer When a method needs to be accessed even before the creation of the object of the class then we should declare the method as static.
Report Error

View answer Workspace Report Error Discuss

Subject: Java

Q:

What are the restriction imposed on a static method or a static block of code?

Answer A static method should not refer to instance variables without creating an instance and cannot use "this" operator to refer the instance.
Report Error

View answer Workspace Report Error Discuss

Subject: Java

Q:

I want to print "Hello" even before main() is executed. How will you acheive that?

Answer Print the statement inside a static block of code. Static blocks get executed when the class gets loaded into the memory and even before the creation of an object. Hence it will be executed before the main() method. And it will be executed only once.
Report Error

View answer Workspace Report Error Discuss

Subject: Java

Q:

I do not want my class to be inherited by any other class. What should i do?

Answer You should declared your class as final. But you can't define your class as final, if it is an abstract class. A class declared as final can't be extended by any other class.
Report Error

View answer Workspace Report Error Discuss

Subject: Java

Q:

What is the impact of declaring a method as final?

Answer A method declared as final can't be overridden. A sub-class can't have the same method signature with a different implementation.
Report Error

View answer Workspace Report Error Discuss

Subject: Java