Files
freeCodeCamp/guide/chinese/java/throw-keyword/index.md
2018-10-16 21:32:40 +05:30

17 lines
390 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
title: Throw
localeTitle: 扔
---
## 扔
Java throw关键字用于显式抛出异常。您可以通过throw关键字在java中抛出checked或uncheked异常。 throw关键字主要用于抛出自定义异常。
**_例_**
```java
throw new ArithmeticException("/ by zero not permitted");
```
##### 更多资源
[极客的极客](https://www.geeksforgeeks.org/throw-throws-java/)