From 6b94afd5c138816558fe2f081df4856b6ddadcad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B9=B3=E5=B1=B1=E3=80=80=E7=B4=97=E5=B8=86?= <26-s-hirayama-stellatecnica@it-college.co.jp> Date: Wed, 7 Oct 2026 16:55:00 +0900 Subject: [PATCH] =?UTF-8?q?1=E6=97=A5=E7=9B=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- StringCheck_20261007_平山.java | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 StringCheck_20261007_平山.java diff --git a/StringCheck_20261007_平山.java b/StringCheck_20261007_平山.java new file mode 100644 index 0000000..452247a --- /dev/null +++ b/StringCheck_20261007_平山.java @@ -0,0 +1,25 @@ + +public class StringCheck { + + public static void main(String[] args) { + // TODO 自動生成されたメソッド・スタブ + String [] name = {"いまなにしてる?", "何も入力されていません", "投稿文が長すぎます","↓↓↓↓↓↓ 投稿されました ↓↓↓↓↓↓"}; + + System.out.println(name[0]); + + String str; + + str = " 今日は晴れ "; + + System.out.println(str.trim()); + + System.out.println(name[3]); + + System.out.println(str.trim()); + + System.out.println(140 - str.length()); + + + } + +}