07/03/24 03:43:56
一応せっかくなので貼っておきますね。
java 6 以上とscripting engine URLリンク(scripting.dev.java.net) が必要
====ここから====
import javax.script.*;
public class main {
static int MIN_SIZE = 2;
static int MAX_SIZE = 3;
static int MAX_NEST = 2;
static String [] relations = new String [] {"&&", "||", "&", "|", "^", "==", "!="};
static final boolean random (final double d) {
return (Math.random () > d);
static final int random (final int n1, final int n2) {
return (int) (Math.abs (n1 - n2) * Math.random () + ((n1 < n2) ? n1: n2));
}