What is the difference between throw and throws?

Answer Posted / sushma

'throw' exception is thrown manually and 'throws' exception
is thrown predefindly.

Is This Answer Correct ?    23 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

I am a fresher and know core java, c languge, html, css etc if I am illegible for any job then send it on my email tatranakshay276@gmail.com

1068


Can we pass a primitive type by reference in java? How

525


Find the value of a specified element of the array arr[i] where 0 <= i <= n-1

533


Why java is made?

560


How does regex work?

517






How many types of variables are there?

666


What is static and final keyword in java?

573


can used Protected Class outside Function.?

608


Why is core java important?

570


Are the imports checked for validity at compile time? Will the code containing an import such as java.lang.abcd compile?

589


Where is java located?

491


What are the basic control structures?

493


What is executor memory?

511


Is it possible to cast an int value into a byte variable? What would happen if the value of int is larger than byte?

540


Describe what a thread-local variable is in java?

563