master
parent
8a326f55b1
commit
ca0be39ee7
|
@ -2,18 +2,18 @@ package inputOutput;
|
||||||
public class DemoConsole {
|
public class DemoConsole {
|
||||||
public static void main(String[] args) throws Exception {
|
public static void main(String[] args) throws Exception {
|
||||||
System.out.println("Text eingeben: ");
|
System.out.println("Text eingeben: ");
|
||||||
String text = Console.readString();
|
String text = DemoConsole.readString();
|
||||||
System.out.println("Gelesener Text: " + text);
|
System.out.println("Gelesener Text: " + text);
|
||||||
|
|
||||||
System.out.println("Text eingeben: ");
|
System.out.println("Text eingeben: ");
|
||||||
char [] ca = Console.readCharArray();
|
char [] ca = DemoConsole.readCharArray();
|
||||||
System.out.println("Gelesenes char-Feld: ");
|
System.out.println("Gelesenes char-Feld: ");
|
||||||
for(char celement: ca)
|
for(char celement: ca)
|
||||||
System.out.print(celement);
|
System.out.print(celement);
|
||||||
System.out.println();
|
System.out.println();
|
||||||
|
|
||||||
System.out.println("Boolean eingeben: ");
|
System.out.println("Boolean eingeben: ");
|
||||||
boolean b = Console.readBoolean();
|
boolean b = DemoConsole.readBoolean();
|
||||||
System.out.println("Gelesener Wert: " + b);
|
System.out.println("Gelesener Wert: " + b);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue