Java replace all string, replacing all numbers less than 3
<pre><code>public static enum pie {
    APPLE_PIE1(1, 250),
    PUMPKIN_PIE1(2, 300),
    OTHER_PIE1(3, 350),
    APPLE_PIE2(4, 400),
    OTHER_PIE2(5, 450),
    PUMPKIN_PIE2(6, 500),
    APPLE_PIE3(7, 550),
    ;
    private static Map&lt;Integer, pie&gt; pie = new HashMap&lt;Integer, pie&gt;();
    static {
        for(pie pie : pie.values()) {
            pie.put(pie.getId(), pie);
        }
    }

    public static pie forId(int id) {
        return pie.get(id);
    }

    private pie(int id, double exp) {
        this.id = id;
        this.exp = exp;
    }

    public int id;
    public double exp;


    System.out.println("My favorite type of pie is " + pie.toString().toLowerCase().replaceAll("_", " ").replaceAll("2", "").replaceAll("3", "").replaceAll("4", "") + ".");
</code></pre>

<p>Example code ripped up, but how would I make that '.replaceAll("<em>number</em>", "")' replace all numbers less than or equal to 4 with a more simple code? Creating a new .replaceAll 3 times is redundant. If I do...:</p>

<pre><code>    double number[] = {1, 2, 3, 4};

    pie.toString().toLowerCase().replaceAll("_", " ").replaceAll(number.toString(), "") + ".");
</code></pre>

<p>...I'll get a nasty error.</p>

<p>Here's the error...</p>

<pre><code>SEVERE: An error occurred in an executor service! The server will be halted immediately.
java.util.regex.PatternSyntaxException: Unclosed character class near index 9
[D@12452e8
        ^
at java.util.regex.Pattern.error(Unknown Source)
at java.util.regex.Pattern.clazz(Unknown Source)
at java.util.regex.Pattern.sequence(Unknown Source)
at java.util.regex.Pattern.expr(Unknown Source)
at java.util.regex.Pattern.compile(Unknown Source)
at java.util.regex.Pattern.&lt;init&gt;(Unknown Source)
at java.util.regex.Pattern.compile(Unknown Source)
at java.lang.String.replaceAll(Unknown Source)
</code></pre>
