Demo entry 6635766

ConsoleTest

   

Submitted by anonymous on Aug 19, 2017 at 16:26
Language: Java. Code size: 518 Bytes.

import java.io.*;

class ConsoleTest {
    public static void main(String args[]) {
        int i = 1;
        double d;
        String s;
        while (i != 0) {
            i = Console.readInt("int eingeben: ");
            System.out.println("eingegeben: " + i);
            d = Console.readDouble("double eingeben: ");
            System.out.println("eingegeben: " + d);
            s = Console.readLine("String eingeben: ");
            System.out.println("eingegeben: " + s);
        }
    }
}

This snippet took 0.00 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).