Sha256: 3d6f3f8123c5e0c5d59e128c4c064749910972455d71c50b9d3a0470e6ceea92

Contents?: true

Size: 400 Bytes

Versions: 281

Compression:

Stored size: 400 Bytes

Contents

import java.util.Arrays;
import java.util.stream.Collectors;

public class PangramChecker {
    private static final int alphaLength = 26;

    public boolean isPangram(String input) {
        return Arrays.stream(input.replaceAll("[^a-zA-Z]", "")
                .toLowerCase()
                .split(""))
                .collect(Collectors.toSet())
                .size() == alphaLength;
    }
}

Version data entries

281 entries across 281 versions & 1 rubygems

Version Path
trackler-2.2.1.18 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.17 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.16 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.15 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.14 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.13 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.12 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.11 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.10 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.9 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.8 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.7 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.6 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.5 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.4 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.3 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.2 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.1 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.1.0 tracks/java/exercises/pangram/src/example/java/PangramChecker.java
trackler-2.2.0.6 tracks/java/exercises/pangram/src/example/java/PangramChecker.java