what is difference between throw and throws in exception?

Answer Posted / prasanna

throw - It is used to throw an Exception.
throws - This is used to specifies that the method can
throw Exception

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do you sort in java?

599


What is ascii code?

645


What do you mean by an object in java?

635


Is null an object in java?

567


Which class should you use to obtain design information about an object in java programming?

651






Explain the significance of class loaders in bootstrap?

502


What is a stack class in java ?

614


What is difference between local variable and global variable?

478


What is port number in java?

597


How are the elements of a gridbaglayout organized in java programming?

524


What is methodological framework?

578


What is preflight request?

532


How many decimal digits is 64 bit?

536


What is an arraylist in java?

517


What methods are used in Servlet?Applet communication?

1669