Add Java-Kompendium book
This commit is contained in:
15
Java-Kompendium/kap6/Task2.java
Normal file
15
Java-Kompendium/kap6/Task2.java
Normal file
@@ -0,0 +1,15 @@
|
||||
import java.util.*;
|
||||
import java.io.*;
|
||||
|
||||
public class Task2 {
|
||||
public static void main(String[] args) throws IOException {
|
||||
var workers = new ArrayList<String>();
|
||||
var stream = new InputStreamReader(System.in);
|
||||
var bufferedStream = new BufferedReader(stream);
|
||||
|
||||
for (int i = 0; i < 5; ++i) {
|
||||
workers.add(bufferedStream.readLine());
|
||||
}
|
||||
System.out.println("Folgende Mitarbeiter haben sie angegeben: " + workers);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user