try-catch tag

4 questions


1 answers
128 views
0
Can you handle multiple exceptions in the same catch statement when handling exceptions?

When we make an exception in Java.try { ... } } catch (IllegalArgumentException e) { someCode();} } catch (SecurityException e) { someCode();} } catch (IllegalAccessException e) { someCode();} } catc...

2 years ago

1 answers
125 views
0
Do I have to make an exception for all the blocks?

In the case of reducing the exception, it is safe to deal with exceptions.Then should I make an exception by using all those blocks as a try-catch?Doesn't that make the code too messy?


1 answers
78 views
0
Javascript: Try-catch Overlapping

Hello.The three queries below are conditions, so I want to write a prerequisite first and write a condition statement, but if one of those queries is undefined, the code stops due to an error.const ge...


1 answers
90 views
0
This is a question about the state of putting the try-catch inside the while.

public static void main(String[] args) { Scanner scanner = new Scanner(System.in); System.out.println (Determine if the digit 10 and the digit 1 are the same.); System.out.println (Enter 0 to stop; Sy...

2 years ago

© 2024 OneMinuteCode. All rights reserved.