Quantcast
Channel: 配列タグが付けられた新着記事 - Qiita
Viewing all articles
Browse latest Browse all 757

例外処理を使ったプログラム実験です

$
0
0
例外処理を使ったプログラム実験です //例外処理を使ったプログラム実験 // Author 2021/06/27 乃木坂好きのITエンジニア public class Moshi17A { public static void main(String[] args) { String[] ary = new String[3]; for(int i=0;i<ary.length;i++) { try { System.out.println(ary[i].concat("Java ")); } catch(NullPointerException e) { System.out.println("データに問題があります"); } finally { System.out.println("続きます"); } } } }

Viewing all articles
Browse latest Browse all 757

Trending Articles