{{ message }}

Instantly share code, notes, and snippets.

# mokomokohitsuzi

Created Jan 16, 2017

View En07_17.java
 import java.util.Scanner; public class En07_17 { public static void main(String[] args) { Scanner stdIn = new Scanner(System.in); System.out.print("要素数："); int num = stdIn.nextInt(); int[] x = new int[num];
Created Jan 14, 2017

View En07_16.java
 import java.util.Random; import java.util.Scanner; public class En07_16 { public static void main(String[] args) { Scanner stdIn = new Scanner(System.in); Random rand = new Random(); System.out.print("配列aの要素数：");
Created Jan 12, 2017

View En07_15.java
 import java.util.Random; import java.util.Scanner; public class En07_15 { public static void main(String[] args) { Scanner stdIn = new Scanner(System.in); Random rand = new Random(); System.out.print("配列aの要素数：");
Created Jan 9, 2017

View En07_10.java
 import java.util.Random; import java.util.Scanner; public class En07_10 { static Scanner stdIn = new Scanner(System.in); public static void main(String[] args) { Random rand = new Random();
Created Jan 9, 2017

View En07_09.java
 import java.util.Scanner; public class En07_09 { public static void main(String[] args) { // メソッド読び出し int n; do { n = readPlusInt(); } while (n <= 0);
Last active Jan 7, 2017

View En07_08.java
 /* * a以上b未満の乱数を生成して、その値を返却するメソッド【int random(int a,int b)】を * 作成せよ。内部で乱数を生成する標準ライブラリを呼び出すこと。 * なお、bの値がaより小さい場合には、aの値をそのまま返却すること。 */ package hukusyuu.en07; import java.util.Random; import java.util.Scanner;
Created Jan 4, 2017

View En07_07.java
 import java.util.Scanner; public class En07_07 { public static void main(String[] args) { Scanner stdIn = new Scanner(System.in); System.out.println("左下直角の直角三角形を表示します"); System.out.print("段数は："); int n = stdIn.nextInt();
Created Dec 28, 2016

View En07_06.java
 import java.util.Scanner; public class En07_06 { public static void main(String[] args) { Scanner stdIn = new Scanner(System.in); System.out.println("季節を表示します。"); System.out.print("月を入力して下さい。："); int m = stdIn.nextInt();
Created Dec 27, 2016

View En07_05.java
 public class En07_05 { public static void main(String[] args) { hello(); } // System.out.printlnで表示するメソッド static void hello() { System.out.println("こんにちは。");
Created Dec 26, 2016

View En07_04.java
 import java.util.Scanner; public class En07_04 { public static void main(String[] args) { Scanner stdIn = new Scanner(System.in); System.out.println("1からnまでの全整数を加算します。"); int n; do {