From bdadc3b88b066691cf8bef892d738b80e3685de4 Mon Sep 17 00:00:00 2001 From: ifembanefo Date: Tue, 2 May 2023 08:47:11 +0200 Subject: [PATCH] =?UTF-8?q?pr=C3=BCfungsanmeldung?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 2Semester/src/Set/Pruefungsanmeldung.java | 38 +++++++++++++++++++ .../src/postfixNotation/package-info.java | 1 - 2 files changed, 38 insertions(+), 1 deletion(-) create mode 100644 2Semester/src/Set/Pruefungsanmeldung.java delete mode 100644 2Semester/src/postfixNotation/package-info.java diff --git a/2Semester/src/Set/Pruefungsanmeldung.java b/2Semester/src/Set/Pruefungsanmeldung.java new file mode 100644 index 0000000..ac1d494 --- /dev/null +++ b/2Semester/src/Set/Pruefungsanmeldung.java @@ -0,0 +1,38 @@ +package Set; + +import java.io.PrintStream; +import java.util.*; + +public class Pruefungsanmeldung { + TreeSet anmeldung = new TreeSet(); + + public boolean anmelden(Student student) { + if ((anmeldung.contains(student))) + return false; + else { + anmeldung.add(student); + return true; + } + } + + public class Student { + + public Student(double mtrn, String nn, String vn, String pm) { + matrikelnr = mtrn; + nachname = nn; + vorname = vn; + prüfungsmodul = pm; + } + + double matrikelnr; + String nachname; + String vorname; + String prüfungsmodul; + + } + + public static void main (String []args) { + PrintStream cons=System.out; + + } +} diff --git a/2Semester/src/postfixNotation/package-info.java b/2Semester/src/postfixNotation/package-info.java deleted file mode 100644 index 7f26a5e..0000000 --- a/2Semester/src/postfixNotation/package-info.java +++ /dev/null @@ -1 +0,0 @@ -package postfixNotation; \ No newline at end of file