Submission #6044873


Source Code Expand

import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author dyominov
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        ASnukesFavoriteYAKINIKU solver = new ASnukesFavoriteYAKINIKU();
        solver.solve(1, in, out);
        out.close();
    }

    static class ASnukesFavoriteYAKINIKU {
        public void solve(int testNumber, InputReader in, PrintWriter out) {
            String s = in.next();
            out.println(s.startsWith("YAKI") ? "Yes" : "No");
        }

    }

    static class InputReader implements AutoCloseable {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public void close() {
        }

    }
}

Submission Info

Submission Time
Task A - Snuke's favorite YAKINIKU
User dyominov
Language Java8 (OpenJDK 1.8.0)
Score 100
Code Size 1792 Byte
Status AC
Exec Time 73 ms
Memory 21716 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 100 / 100
Status
AC × 3
AC × 16
Set Name Test Cases
Sample s1.txt, s2.txt, s3.txt
All 01.txt, 02.txt, 03.txt, 04.txt, 05.txt, 06.txt, 07.txt, 08.txt, 09.txt, 10.txt, 11.txt, 12.txt, 13.txt, s1.txt, s2.txt, s3.txt
Case Name Status Exec Time Memory
01.txt AC 70 ms 19412 KB
02.txt AC 69 ms 21332 KB
03.txt AC 68 ms 17620 KB
04.txt AC 71 ms 19280 KB
05.txt AC 70 ms 19156 KB
06.txt AC 70 ms 20180 KB
07.txt AC 69 ms 19412 KB
08.txt AC 70 ms 18900 KB
09.txt AC 70 ms 18772 KB
10.txt AC 73 ms 21716 KB
11.txt AC 69 ms 18772 KB
12.txt AC 68 ms 18644 KB
13.txt AC 70 ms 18388 KB
s1.txt AC 70 ms 21076 KB
s2.txt AC 68 ms 20052 KB
s3.txt AC 69 ms 19924 KB