import java.io.*;
import java.util.NoSuchElementException;

public class Main {
    public static void main(String[] args) {
        try (BufferedScanner in = new BufferedScanner();
             PrintWriter out = new PrintWriter(System.out)) {
            //
            int n = in.nextInt();
            int m = in.nextInt();
            int[] answer = new int[n];

            for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            }

            for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            }

        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}

class BufferedScanner implements Closeable {
    private InputStream in = System.in;
    private int BUFFER_SIZE = 65536;
    private int toBuffers = 0;
    private byte buffer[] = new byte[BUFFER_SIZE];
    private int nextByte = 0;

    boolean isEOF() {
        if (nextByte >= toBuffers) {
            fill();
            if (nextByte >= toBuffers) {
                return true;
            }
        }
        return false;
    }

    private void fill() {
        nextByte = 0;

        try {
            toBuffers = in.read(buffer);
        } catch (IOException e) {
            throw new UncheckedIOException(e);
        }
    }

    private int read() {
        if (isEOF()) {
            return -1;
        }
        return buffer[nextByte++];
    }

    String nextLine() {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        int now;
        for (now = read(); isPrintableByte(now) || now == ' '; now = read()) {
            result.append((char) now);
        }

        if (now == '\r') {
            now = read();
        }

        if (now == '\n') {
            read();
            return result.toString();
        }
        throw new IllegalArgumentException("???");
    }

    String next() {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        for (int now = read(); isPrintableByte(now); now = read()) {
            result.append((char) now);
        }

        return result.toString();
    }

    long nextLong() {
        if (!hasNext()) {
            throw new NoSuchElementException("EOF");
        }

        boolean isMinus;
        int result = 0;
        int now = read();
        if (now == '-') {
            isMinus = true;
            now = read();
        } else if (isNumber(now)) {
            isMinus = false;
        } else {
            throw new NumberFormatException("notNumber");
        }


        for (; isNumber(now); now = read()) {
            result = result * 10 + (now & 15);
        }

        if (!isNumber(now) || now == -1) {
            return isMinus ? -result : result;
        }

        throw new NumberFormatException("notNumber?");
    }

    int nextInt() {
        long result = nextLong();
        if (result > Integer.MAX_VALUE || result < Integer.MIN_VALUE) {
            throw new NoSuchElementException("isLong");
        }
        return (int) result;
    }

    double nextDouble() {
        return Double.parseDouble(next());
    }

    boolean hasNext() {
        while (!isEOF() && !isPrintableByte(buffer[nextByte])) {
            ++nextByte;
        }
        return !isEOF();
    }


    private static boolean isPrintableByte(int c) {
        return ' ' < c && c <= 126;
    }

    private static boolean isNumber(int n) {
        return n >= '0' && n <= '9';
    }

    @Override
    public void close() throws IOException {
        in.close();
    }
} import java.io.*; io.* java import java.util.NoSuchElementException; NoSuchElementException java.util public class Main {
    public static void main(String[] args) {
        try (BufferedScanner in = new BufferedScanner();
             PrintWriter out = new PrintWriter(System.out)) {
            //
            int n = in.nextInt();
            int m = in.nextInt();
            int[] answer = new int[n];

            for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            }

            for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            }

        } catch (IOException e) {
            e.printStackTrace();
        }
    }
} Main public static void main(String[] args) {
        try (BufferedScanner in = new BufferedScanner();
             PrintWriter out = new PrintWriter(System.out)) {
            //
            int n = in.nextInt();
            int m = in.nextInt();
            int[] answer = new int[n];

            for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            }

            for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            }

        } catch (IOException e) {
            e.printStackTrace();
        }
    } main {
        try (BufferedScanner in = new BufferedScanner();
             PrintWriter out = new PrintWriter(System.out)) {
            //
            int n = in.nextInt();
            int m = in.nextInt();
            int[] answer = new int[n];

            for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            }

            for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            }

        } catch (IOException e) {
            e.printStackTrace();
        }
    } try (BufferedScanner in = new BufferedScanner();
             PrintWriter out = new PrintWriter(System.out)) {
            //
            int n = in.nextInt();
            int m = in.nextInt();
            int[] answer = new int[n];

            for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            }

            for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            }

        } catch (IOException e) {
            e.printStackTrace();
        } catch (IOException e) {
            e.printStackTrace();
        } IOException e {
            e.printStackTrace();
        } e.printStackTrace() e.printStackTrace e {
            //
            int n = in.nextInt();
            int m = in.nextInt();
            int[] answer = new int[n];

            for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            }

            for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            }

        } BufferedScanner in = new BufferedScanner() BufferedScanner in = new BufferedScanner() new BufferedScanner() PrintWriter out = new PrintWriter(System.out) PrintWriter out = new PrintWriter(System.out) new PrintWriter(System.out) int n = in.nextInt(); n in.nextInt() in.nextInt in int m = in.nextInt(); m in.nextInt() in.nextInt in int[] answer = new int[n]; answer new int[n] n for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            } int i = 0; int i = 0; i 0 i < m i m ++i ++i i {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            } {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            } int a = in.nextInt() - 1; a in.nextInt() - 1 in.nextInt() in.nextInt in 1 int b = in.nextInt() - 1; b in.nextInt() - 1 in.nextInt() in.nextInt in 1 answer[a]++ answer[a] answer a answer[b]++ answer[b] answer b for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            } int i = 0; int i = 0; i 0 i < n i n ++i ++i i {
                out.println(answer[i]);
            } {
                out.println(answer[i]);
            } out.println(answer[i]) out.println out answer[i] answer i String[] args args class BufferedScanner implements Closeable {
    private InputStream in = System.in;
    private int BUFFER_SIZE = 65536;
    private int toBuffers = 0;
    private byte buffer[] = new byte[BUFFER_SIZE];
    private int nextByte = 0;

    boolean isEOF() {
        if (nextByte >= toBuffers) {
            fill();
            if (nextByte >= toBuffers) {
                return true;
            }
        }
        return false;
    }

    private void fill() {
        nextByte = 0;

        try {
            toBuffers = in.read(buffer);
        } catch (IOException e) {
            throw new UncheckedIOException(e);
        }
    }

    private int read() {
        if (isEOF()) {
            return -1;
        }
        return buffer[nextByte++];
    }

    String nextLine() {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        int now;
        for (now = read(); isPrintableByte(now) || now == ' '; now = read()) {
            result.append((char) now);
        }

        if (now == '\r') {
            now = read();
        }

        if (now == '\n') {
            read();
            return result.toString();
        }
        throw new IllegalArgumentException("???");
    }

    String next() {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        for (int now = read(); isPrintableByte(now); now = read()) {
            result.append((char) now);
        }

        return result.toString();
    }

    long nextLong() {
        if (!hasNext()) {
            throw new NoSuchElementException("EOF");
        }

        boolean isMinus;
        int result = 0;
        int now = read();
        if (now == '-') {
            isMinus = true;
            now = read();
        } else if (isNumber(now)) {
            isMinus = false;
        } else {
            throw new NumberFormatException("notNumber");
        }


        for (; isNumber(now); now = read()) {
            result = result * 10 + (now & 15);
        }

        if (!isNumber(now) || now == -1) {
            return isMinus ? -result : result;
        }

        throw new NumberFormatException("notNumber?");
    }

    int nextInt() {
        long result = nextLong();
        if (result > Integer.MAX_VALUE || result < Integer.MIN_VALUE) {
            throw new NoSuchElementException("isLong");
        }
        return (int) result;
    }

    double nextDouble() {
        return Double.parseDouble(next());
    }

    boolean hasNext() {
        while (!isEOF() && !isPrintableByte(buffer[nextByte])) {
            ++nextByte;
        }
        return !isEOF();
    }


    private static boolean isPrintableByte(int c) {
        return ' ' < c && c <= 126;
    }

    private static boolean isNumber(int n) {
        return n >= '0' && n <= '9';
    }

    @Override
    public void close() throws IOException {
        in.close();
    }
} BufferedScanner private InputStream in = System.in; in System.in System System.in private int BUFFER_SIZE = 65536; BUFFER_SIZE 65536 private int toBuffers = 0; toBuffers 0 private byte buffer[] = new byte[BUFFER_SIZE]; buffer new byte[BUFFER_SIZE] BUFFER_SIZE private int nextByte = 0; nextByte 0 boolean isEOF() {
        if (nextByte >= toBuffers) {
            fill();
            if (nextByte >= toBuffers) {
                return true;
            }
        }
        return false;
    } isEOF {
        if (nextByte >= toBuffers) {
            fill();
            if (nextByte >= toBuffers) {
                return true;
            }
        }
        return false;
    } if (nextByte >= toBuffers) {
            fill();
            if (nextByte >= toBuffers) {
                return true;
            }
        } nextByte >= toBuffers nextByte toBuffers {
            fill();
            if (nextByte >= toBuffers) {
                return true;
            }
        } fill() fill if (nextByte >= toBuffers) {
                return true;
            } nextByte >= toBuffers nextByte toBuffers {
                return true;
            } return true; true return false; false private void fill() {
        nextByte = 0;

        try {
            toBuffers = in.read(buffer);
        } catch (IOException e) {
            throw new UncheckedIOException(e);
        }
    } fill {
        nextByte = 0;

        try {
            toBuffers = in.read(buffer);
        } catch (IOException e) {
            throw new UncheckedIOException(e);
        }
    } nextByte = 0 nextByte 0 try {
            toBuffers = in.read(buffer);
        } catch (IOException e) {
            throw new UncheckedIOException(e);
        } catch (IOException e) {
            throw new UncheckedIOException(e);
        } IOException e {
            throw new UncheckedIOException(e);
        } throw new UncheckedIOException(e); new UncheckedIOException(e) {
            toBuffers = in.read(buffer);
        } toBuffers = in.read(buffer) toBuffers in.read(buffer) in.read in buffer private int read() {
        if (isEOF()) {
            return -1;
        }
        return buffer[nextByte++];
    } read {
        if (isEOF()) {
            return -1;
        }
        return buffer[nextByte++];
    } if (isEOF()) {
            return -1;
        } isEOF() isEOF {
            return -1;
        } return -1; -1 1 return buffer[nextByte++]; buffer[nextByte++] buffer nextByte++ nextByte String nextLine() {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        int now;
        for (now = read(); isPrintableByte(now) || now == ' '; now = read()) {
            result.append((char) now);
        }

        if (now == '\r') {
            now = read();
        }

        if (now == '\n') {
            read();
            return result.toString();
        }
        throw new IllegalArgumentException("???");
    } nextLine {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        int now;
        for (now = read(); isPrintableByte(now) || now == ' '; now = read()) {
            result.append((char) now);
        }

        if (now == '\r') {
            now = read();
        }

        if (now == '\n') {
            read();
            return result.toString();
        }
        throw new IllegalArgumentException("???");
    } if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        } !hasNext() hasNext() hasNext {
            return null;
            //throw new NoSuchElementException("EOF");
        } return null; null StringBuilder result = new StringBuilder(); result new StringBuilder() int now; now for (now = read(); isPrintableByte(now) || now == ' '; now = read()) {
            result.append((char) now);
        } now = read(); now = read() now read() read isPrintableByte(now) || now == ' ' isPrintableByte(now) isPrintableByte now now == ' ' now ' ' now = read() now = read() now read() read {
            result.append((char) now);
        } {
            result.append((char) now);
        } result.append((char) now) result.append result (char) now if (now == '\r') {
            now = read();
        } now == '\r' now '\r' {
            now = read();
        } now = read() now read() read if (now == '\n') {
            read();
            return result.toString();
        } now == '\n' now '\n' {
            read();
            return result.toString();
        } read() read return result.toString(); result.toString() result.toString result throw new IllegalArgumentException("???"); new IllegalArgumentException("???") String next() {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        for (int now = read(); isPrintableByte(now); now = read()) {
            result.append((char) now);
        }

        return result.toString();
    } next {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        for (int now = read(); isPrintableByte(now); now = read()) {
            result.append((char) now);
        }

        return result.toString();
    } if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        } !hasNext() hasNext() hasNext {
            return null;
            //throw new NoSuchElementException("EOF");
        } return null; null StringBuilder result = new StringBuilder(); result new StringBuilder() for (int now = read(); isPrintableByte(now); now = read()) {
            result.append((char) now);
        } int now = read(); int now = read(); now read() read isPrintableByte(now) isPrintableByte now now = read() now = read() now read() read {
            result.append((char) now);
        } {
            result.append((char) now);
        } result.append((char) now) result.append result (char) now return result.toString(); result.toString() result.toString result long nextLong() {
        if (!hasNext()) {
            throw new NoSuchElementException("EOF");
        }

        boolean isMinus;
        int result = 0;
        int now = read();
        if (now == '-') {
            isMinus = true;
            now = read();
        } else if (isNumber(now)) {
            isMinus = false;
        } else {
            throw new NumberFormatException("notNumber");
        }


        for (; isNumber(now); now = read()) {
            result = result * 10 + (now & 15);
        }

        if (!isNumber(now) || now == -1) {
            return isMinus ? -result : result;
        }

        throw new NumberFormatException("notNumber?");
    } nextLong {
        if (!hasNext()) {
            throw new NoSuchElementException("EOF");
        }

        boolean isMinus;
        int result = 0;
        int now = read();
        if (now == '-') {
            isMinus = true;
            now = read();
        } else if (isNumber(now)) {
            isMinus = false;
        } else {
            throw new NumberFormatException("notNumber");
        }


        for (; isNumber(now); now = read()) {
            result = result * 10 + (now & 15);
        }

        if (!isNumber(now) || now == -1) {
            return isMinus ? -result : result;
        }

        throw new NumberFormatException("notNumber?");
    } if (!hasNext()) {
            throw new NoSuchElementException("EOF");
        } !hasNext() hasNext() hasNext {
            throw new NoSuchElementException("EOF");
        } throw new NoSuchElementException("EOF"); new NoSuchElementException("EOF") boolean isMinus; isMinus int result = 0; result 0 int now = read(); now read() read if (now == '-') {
            isMinus = true;
            now = read();
        } else if (isNumber(now)) {
            isMinus = false;
        } else {
            throw new NumberFormatException("notNumber");
        } now == '-' now '-' {
            isMinus = true;
            now = read();
        } isMinus = true isMinus true now = read() now read() read if (isNumber(now)) {
            isMinus = false;
        } else {
            throw new NumberFormatException("notNumber");
        } isNumber(now) isNumber now {
            isMinus = false;
        } isMinus = false isMinus false {
            throw new NumberFormatException("notNumber");
        } throw new NumberFormatException("notNumber"); new NumberFormatException("notNumber") for (; isNumber(now); now = read()) {
            result = result * 10 + (now & 15);
        } ; isNumber(now) isNumber now now = read() now = read() now read() read {
            result = result * 10 + (now & 15);
        } {
            result = result * 10 + (now & 15);
        } result = result * 10 + (now & 15) result result * 10 + (now & 15) result * 10 result 10 (now & 15) now 15 if (!isNumber(now) || now == -1) {
            return isMinus ? -result : result;
        } !isNumber(now) || now == -1 !isNumber(now) isNumber(now) isNumber now now == -1 now -1 1 {
            return isMinus ? -result : result;
        } return isMinus ? -result : result; isMinus ? -result : result isMinus -result result result throw new NumberFormatException("notNumber?"); new NumberFormatException("notNumber?") int nextInt() {
        long result = nextLong();
        if (result > Integer.MAX_VALUE || result < Integer.MIN_VALUE) {
            throw new NoSuchElementException("isLong");
        }
        return (int) result;
    } nextInt {
        long result = nextLong();
        if (result > Integer.MAX_VALUE || result < Integer.MIN_VALUE) {
            throw new NoSuchElementException("isLong");
        }
        return (int) result;
    } long result = nextLong(); result nextLong() nextLong if (result > Integer.MAX_VALUE || result < Integer.MIN_VALUE) {
            throw new NoSuchElementException("isLong");
        } result > Integer.MAX_VALUE || result < Integer.MIN_VALUE result > Integer.MAX_VALUE result Integer.MAX_VALUE Integer Integer.MAX_VALUE result < Integer.MIN_VALUE result Integer.MIN_VALUE Integer Integer.MIN_VALUE {
            throw new NoSuchElementException("isLong");
        } throw new NoSuchElementException("isLong"); new NoSuchElementException("isLong") return (int) result; (int) result double nextDouble() {
        return Double.parseDouble(next());
    } nextDouble {
        return Double.parseDouble(next());
    } return Double.parseDouble(next()); Double.parseDouble(next()) Double.parseDouble Double next() next boolean hasNext() {
        while (!isEOF() && !isPrintableByte(buffer[nextByte])) {
            ++nextByte;
        }
        return !isEOF();
    } hasNext {
        while (!isEOF() && !isPrintableByte(buffer[nextByte])) {
            ++nextByte;
        }
        return !isEOF();
    } while (!isEOF() && !isPrintableByte(buffer[nextByte])) {
            ++nextByte;
        } !isEOF() && !isPrintableByte(buffer[nextByte]) !isEOF() isEOF() isEOF !isPrintableByte(buffer[nextByte]) isPrintableByte(buffer[nextByte]) isPrintableByte buffer[nextByte] buffer nextByte {
            ++nextByte;
        } ++nextByte nextByte return !isEOF(); !isEOF() isEOF() isEOF private static boolean isPrintableByte(int c) {
        return ' ' < c && c <= 126;
    } isPrintableByte {
        return ' ' < c && c <= 126;
    } return ' ' < c && c <= 126; ' ' < c && c <= 126 ' ' < c ' ' c c <= 126 c 126 int c c private static boolean isNumber(int n) {
        return n >= '0' && n <= '9';
    } isNumber {
        return n >= '0' && n <= '9';
    } return n >= '0' && n <= '9'; n >= '0' && n <= '9' n >= '0' n '0' n <= '9' n '9' int n n @Override
    public void close() throws IOException {
        in.close();
    } close {
        in.close();
    } in.close() in.close in Closeable public class Main {
    public static void main(String[] args) {
        try (BufferedScanner in = new BufferedScanner();
             PrintWriter out = new PrintWriter(System.out)) {
            //
            int n = in.nextInt();
            int m = in.nextInt();
            int[] answer = new int[n];

            for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            }

            for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            }

        } catch (IOException e) {
            e.printStackTrace();
        }
    }
} public class Main {
    public static void main(String[] args) {
        try (BufferedScanner in = new BufferedScanner();
             PrintWriter out = new PrintWriter(System.out)) {
            //
            int n = in.nextInt();
            int m = in.nextInt();
            int[] answer = new int[n];

            for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            }

            for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            }

        } catch (IOException e) {
            e.printStackTrace();
        }
    }
} Main
import java.io.*;
import java.util.NoSuchElementException;

public class Main {
    public static void main(String[] args) {
        try (BufferedScanner in = new BufferedScanner();
             PrintWriter out = new PrintWriter(System.out)) {
            //
            int n = in.nextInt();
            int m = in.nextInt();
            int[] answer = new int[n];

            for (int i = 0; i < m; ++i) {
                int a = in.nextInt() - 1;
                int b = in.nextInt() - 1;
                answer[a]++;
                answer[b]++;
            }

            for (int i = 0; i < n; ++i) {
                out.println(answer[i]);
            }

        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}

class BufferedScanner implements Closeable {
    private InputStream in = System.in;
    private int BUFFER_SIZE = 65536;
    private int toBuffers = 0;
    private byte buffer[] = new byte[BUFFER_SIZE];
    private int nextByte = 0;

    boolean isEOF() {
        if (nextByte >= toBuffers) {
            fill();
            if (nextByte >= toBuffers) {
                return true;
            }
        }
        return false;
    }

    private void fill() {
        nextByte = 0;

        try {
            toBuffers = in.read(buffer);
        } catch (IOException e) {
            throw new UncheckedIOException(e);
        }
    }

    private int read() {
        if (isEOF()) {
            return -1;
        }
        return buffer[nextByte++];
    }

    String nextLine() {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        int now;
        for (now = read(); isPrintableByte(now) || now == ' '; now = read()) {
            result.append((char) now);
        }

        if (now == '\r') {
            now = read();
        }

        if (now == '\n') {
            read();
            return result.toString();
        }
        throw new IllegalArgumentException("???");
    }

    String next() {
        if (!hasNext()) {
            return null;
            //throw new NoSuchElementException("EOF");
        }

        StringBuilder result = new StringBuilder();
        for (int now = read(); isPrintableByte(now); now = read()) {
            result.append((char) now);
        }

        return result.toString();
    }

    long nextLong() {
        if (!hasNext()) {
            throw new NoSuchElementException("EOF");
        }

        boolean isMinus;
        int result = 0;
        int now = read();
        if (now == '-') {
            isMinus = true;
            now = read();
        } else if (isNumber(now)) {
            isMinus = false;
        } else {
            throw new NumberFormatException("notNumber");
        }


        for (; isNumber(now); now = read()) {
            result = result * 10 + (now & 15);
        }

        if (!isNumber(now) || now == -1) {
            return isMinus ? -result : result;
        }

        throw new NumberFormatException("notNumber?");
    }

    int nextInt() {
        long result = nextLong();
        if (result > Integer.MAX_VALUE || result < Integer.MIN_VALUE) {
            throw new NoSuchElementException("isLong");
        }
        return (int) result;
    }

    double nextDouble() {
        return Double.parseDouble(next());
    }

    boolean hasNext() {
        while (!isEOF() && !isPrintableByte(buffer[nextByte])) {
            ++nextByte;
        }
        return !isEOF();
    }


    private static boolean isPrintableByte(int c) {
        return ' ' < c && c <= 126;
    }

    private static boolean isNumber(int n) {
        return n >= '0' && n <= '9';
    }

    @Override
    public void close() throws IOException {
        in.close();
    }
}
