diff --git a/.vs/prog2-ss2020-wienkop/v16/.suo b/.vs/prog2-ss2020-wienkop/v16/.suo index 425c9f1426dd7a9619bdd610d62d06dd49ff69be..210a54465796d69ce26051600b849638ab7eb1e5 100644 Binary files a/.vs/prog2-ss2020-wienkop/v16/.suo and b/.vs/prog2-ss2020-wienkop/v16/.suo differ diff --git a/01Buergeramt-Di/obj/Debug/netcoreapp3.1/01Uebg_Buergeramt-Di.csproj.FileListAbsolute.txt b/01Buergeramt-Di/obj/Debug/netcoreapp3.1/01Uebg_Buergeramt-Di.csproj.FileListAbsolute.txt index 5c21a48a6e8f898fa554536c30a668b93230f760..f8cea773916a98d5b3b5ea78ed1fc02382aca68a 100644 --- a/01Buergeramt-Di/obj/Debug/netcoreapp3.1/01Uebg_Buergeramt-Di.csproj.FileListAbsolute.txt +++ b/01Buergeramt-Di/obj/Debug/netcoreapp3.1/01Uebg_Buergeramt-Di.csproj.FileListAbsolute.txt @@ -2,3 +2,7 @@ C:\Users\wienkop\source\repos\01Buergeramt-Di\obj\Debug\netcoreapp3.1\01Uebg_Bue C:\Users\wienkop\source\repos\01Buergeramt-Di\obj\Debug\netcoreapp3.1\01Uebg_Buergeramt-Di.csproj.CoreCompileInputs.cache C:\Users\wienkop\source\repos\01Buergeramt-Di\obj\Debug\netcoreapp3.1\01Uebg_Buergeramt-Di.AssemblyInfoInputs.cache C:\Users\wienkop\source\repos\01Buergeramt-Di\obj\Debug\netcoreapp3.1\01Uebg_Buergeramt-Di.AssemblyInfo.cs +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01Buergeramt-Di\obj\Debug\netcoreapp3.1\01Uebg_Buergeramt-Di.csprojAssemblyReference.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01Buergeramt-Di\obj\Debug\netcoreapp3.1\01Uebg_Buergeramt-Di.csproj.CoreCompileInputs.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01Buergeramt-Di\obj\Debug\netcoreapp3.1\01Uebg_Buergeramt-Di.AssemblyInfoInputs.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01Buergeramt-Di\obj\Debug\netcoreapp3.1\01Uebg_Buergeramt-Di.AssemblyInfo.cs diff --git a/01KlassenWiederholung/obj/Debug/netcoreapp3.1/01KlassenWiederholung.csprojAssemblyReference.cache b/01KlassenWiederholung/obj/Debug/netcoreapp3.1/01KlassenWiederholung.csprojAssemblyReference.cache index 9dfc37ed889ff4d2deed3ec1295b3086aa3c45af..d9eae35234dacaf5d718f698e8a5e7ced3ac76bd 100644 Binary files a/01KlassenWiederholung/obj/Debug/netcoreapp3.1/01KlassenWiederholung.csprojAssemblyReference.cache and b/01KlassenWiederholung/obj/Debug/netcoreapp3.1/01KlassenWiederholung.csprojAssemblyReference.cache differ diff --git a/01OperatorOverloading/bin/Debug/netcoreapp3.1/01OperatorOverloading.dll b/01OperatorOverloading/bin/Debug/netcoreapp3.1/01OperatorOverloading.dll index 3ea145804b2b969b732ee74bab6f1eca720a4c2a..514edda6c297d7a142397611f55e059b7d7989e0 100644 Binary files a/01OperatorOverloading/bin/Debug/netcoreapp3.1/01OperatorOverloading.dll and b/01OperatorOverloading/bin/Debug/netcoreapp3.1/01OperatorOverloading.dll differ diff --git a/01OperatorOverloading/bin/Debug/netcoreapp3.1/01OperatorOverloading.pdb b/01OperatorOverloading/bin/Debug/netcoreapp3.1/01OperatorOverloading.pdb index 5ea2b7bef18f85bcf247da9f6a99b3ddb1f0d626..08d2d56282a92de64a7939ad19f59266318f504e 100644 Binary files a/01OperatorOverloading/bin/Debug/netcoreapp3.1/01OperatorOverloading.pdb and b/01OperatorOverloading/bin/Debug/netcoreapp3.1/01OperatorOverloading.pdb differ diff --git a/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.csprojAssemblyReference.cache b/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.csprojAssemblyReference.cache index 4824caf0c92344f68eac696e04da28b425072d2c..4604200e8108358ecfd89e86f2787c9523eed2ff 100644 Binary files a/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.csprojAssemblyReference.cache and b/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.csprojAssemblyReference.cache differ diff --git a/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.dll b/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.dll index 3ea145804b2b969b732ee74bab6f1eca720a4c2a..514edda6c297d7a142397611f55e059b7d7989e0 100644 Binary files a/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.dll and b/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.dll differ diff --git a/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.pdb b/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.pdb index 5ea2b7bef18f85bcf247da9f6a99b3ddb1f0d626..08d2d56282a92de64a7939ad19f59266318f504e 100644 Binary files a/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.pdb and b/01OperatorOverloading/obj/Debug/netcoreapp3.1/01OperatorOverloading.pdb differ diff --git a/01WPF_Demo/bin/Debug/01WPF_Demo.exe b/01WPF_Demo/bin/Debug/01WPF_Demo.exe index 8516762eb5ba0afe0a374a57efd67eee6f9b6f01..28e74680f329f115ab2c8a617923799a71f2272b 100644 Binary files a/01WPF_Demo/bin/Debug/01WPF_Demo.exe and b/01WPF_Demo/bin/Debug/01WPF_Demo.exe differ diff --git a/01WPF_Demo/bin/Debug/01WPF_Demo.pdb b/01WPF_Demo/bin/Debug/01WPF_Demo.pdb index b86b291e2f42c1e09e38dc9900bbda766e5d7a7a..d1bdb1926fa8d59ecaa03845cac46e11986d0e0a 100644 Binary files a/01WPF_Demo/bin/Debug/01WPF_Demo.pdb and b/01WPF_Demo/bin/Debug/01WPF_Demo.pdb differ diff --git a/01WPF_Demo/obj/Debug/01WPF_Demo.csproj.CoreCompileInputs.cache b/01WPF_Demo/obj/Debug/01WPF_Demo.csproj.CoreCompileInputs.cache index 60a6d33bfce61549a6e788cad838825a5a450d41..fedbbfff72962a4e1068087aa5d80ebe00c4525b 100644 --- a/01WPF_Demo/obj/Debug/01WPF_Demo.csproj.CoreCompileInputs.cache +++ b/01WPF_Demo/obj/Debug/01WPF_Demo.csproj.CoreCompileInputs.cache @@ -1 +1 @@ -d5364dac5220386666072cb31f209f0d45a62d12 +390c570c04e08522ae0e2daf17bc344f788e09e4 diff --git a/01WPF_Demo/obj/Debug/01WPF_Demo.csproj.FileListAbsolute.txt b/01WPF_Demo/obj/Debug/01WPF_Demo.csproj.FileListAbsolute.txt index 4da6bb577773ce0d74c222281192cf13ec6dd9da..78c5f87f3bedc6bf9d8e1225643a0c76baf1b8ed 100644 --- a/01WPF_Demo/obj/Debug/01WPF_Demo.csproj.FileListAbsolute.txt +++ b/01WPF_Demo/obj/Debug/01WPF_Demo.csproj.FileListAbsolute.txt @@ -13,3 +13,18 @@ C:\Users\wienkop\source\repos\01WPF_Demo\obj\Debug\01WPF_Demo.csproj.GenerateRes C:\Users\wienkop\source\repos\01WPF_Demo\obj\Debug\01WPF_Demo.csproj.CoreCompileInputs.cache C:\Users\wienkop\source\repos\01WPF_Demo\obj\Debug\01WPF_Demo.exe C:\Users\wienkop\source\repos\01WPF_Demo\obj\Debug\01WPF_Demo.pdb +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\bin\Debug\01WPF_Demo.exe.config +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\bin\Debug\01WPF_Demo.exe +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\bin\Debug\01WPF_Demo.pdb +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\01WPF_Demo.csprojAssemblyReference.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\MainWindow.g.cs +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\App.g.cs +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\01WPF_Demo_MarkupCompile.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\01WPF_Demo_MarkupCompile.lref +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\MainWindow.baml +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\01WPF_Demo.g.resources +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\_01WPF_Demo.Properties.Resources.resources +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\01WPF_Demo.csproj.GenerateResource.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\01WPF_Demo.csproj.CoreCompileInputs.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\01WPF_Demo.exe +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\obj\Debug\01WPF_Demo.pdb diff --git a/01WPF_Demo/obj/Debug/01WPF_Demo.exe b/01WPF_Demo/obj/Debug/01WPF_Demo.exe index 8516762eb5ba0afe0a374a57efd67eee6f9b6f01..28e74680f329f115ab2c8a617923799a71f2272b 100644 Binary files a/01WPF_Demo/obj/Debug/01WPF_Demo.exe and b/01WPF_Demo/obj/Debug/01WPF_Demo.exe differ diff --git a/01WPF_Demo/obj/Debug/01WPF_Demo.pdb b/01WPF_Demo/obj/Debug/01WPF_Demo.pdb index b86b291e2f42c1e09e38dc9900bbda766e5d7a7a..d1bdb1926fa8d59ecaa03845cac46e11986d0e0a 100644 Binary files a/01WPF_Demo/obj/Debug/01WPF_Demo.pdb and b/01WPF_Demo/obj/Debug/01WPF_Demo.pdb differ diff --git a/01WPF_Demo/obj/Debug/01WPF_Demo_MarkupCompile.cache b/01WPF_Demo/obj/Debug/01WPF_Demo_MarkupCompile.cache index 673b34cea2cac216624a6abe997a252862101b48..a24cc3fe0b24b8d747f994f8422f44d67080ebc5 100644 --- a/01WPF_Demo/obj/Debug/01WPF_Demo_MarkupCompile.cache +++ b/01WPF_Demo/obj/Debug/01WPF_Demo_MarkupCompile.cache @@ -12,9 +12,9 @@ DEBUG;TRACE C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\01WPF_Demo\App.xaml 11151548125 -6-1369348151 +5-2017746502 13-1505183044 MainWindow.xaml; -True +False diff --git a/01WPF_Demo/obj/Debug/MainWindow.baml b/01WPF_Demo/obj/Debug/MainWindow.baml new file mode 100644 index 0000000000000000000000000000000000000000..275dd8523a27e556370b36ad0b8c66af39ffa395 Binary files /dev/null and b/01WPF_Demo/obj/Debug/MainWindow.baml differ diff --git a/02 Uebg KlasseTimeOpOverloading/bin/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.dll b/02 Uebg KlasseTimeOpOverloading/bin/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.dll index cb38fcedbe08cae65bae0d7997ae7cd937452e47..3c9d5e64de45d9aa6f7892082fce12b2146c3209 100644 Binary files a/02 Uebg KlasseTimeOpOverloading/bin/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.dll and b/02 Uebg KlasseTimeOpOverloading/bin/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.dll differ diff --git a/02 Uebg KlasseTimeOpOverloading/bin/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.pdb b/02 Uebg KlasseTimeOpOverloading/bin/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.pdb index 38ee9072a7a69843a7132c0651691c690314fa90..3a2e2cba64c5eec873eea85011f30b4dfeacef7d 100644 Binary files a/02 Uebg KlasseTimeOpOverloading/bin/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.pdb and b/02 Uebg KlasseTimeOpOverloading/bin/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.pdb differ diff --git a/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.csproj.FileListAbsolute.txt b/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.csproj.FileListAbsolute.txt index 3ef0abe8fa81368997d3719970aca567554d315d..0bde73c872c4a2c7ca742d011e4baf92434b8dca 100644 --- a/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.csproj.FileListAbsolute.txt +++ b/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.csproj.FileListAbsolute.txt @@ -11,3 +11,16 @@ C:\Users\wienkop\source\repos\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcorea C:\Users\wienkop\source\repos\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.dll C:\Users\wienkop\source\repos\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.pdb C:\Users\wienkop\source\repos\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.genruntimeconfig.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\bin\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.exe +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\bin\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.deps.json +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\bin\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.runtimeconfig.json +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\bin\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.runtimeconfig.dev.json +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\bin\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.dll +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\bin\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.pdb +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.csprojAssemblyReference.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.csproj.CoreCompileInputs.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.AssemblyInfoInputs.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.AssemblyInfo.cs +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.dll +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.pdb +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\02 Uebg KlasseTimeOpOverloading\obj\Debug\netcoreapp3.1\02 UebgMo KlasseTimeOpOverloading.genruntimeconfig.cache diff --git a/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.dll b/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.dll index cb38fcedbe08cae65bae0d7997ae7cd937452e47..3c9d5e64de45d9aa6f7892082fce12b2146c3209 100644 Binary files a/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.dll and b/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.dll differ diff --git a/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.pdb b/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.pdb index 38ee9072a7a69843a7132c0651691c690314fa90..3a2e2cba64c5eec873eea85011f30b4dfeacef7d 100644 Binary files a/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.pdb and b/02 Uebg KlasseTimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgMo KlasseTimeOpOverloading.pdb differ diff --git a/02 UebgDi Klassse TimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgDi Klassse TimeOpOverloading.csprojAssemblyReference.cache b/02 UebgDi Klassse TimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgDi Klassse TimeOpOverloading.csprojAssemblyReference.cache index a0fbfd12797557adefa2aaaacd9d5126dec64303..9b0e710fb7587c1bf9b43414d9232508a4786d6e 100644 Binary files a/02 UebgDi Klassse TimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgDi Klassse TimeOpOverloading.csprojAssemblyReference.cache and b/02 UebgDi Klassse TimeOpOverloading/obj/Debug/netcoreapp3.1/02 UebgDi Klassse TimeOpOverloading.csprojAssemblyReference.cache differ diff --git a/02VerketteteListe-2/Program.cs b/02VerketteteListe-2/Program.cs index 859812659b4ff76b87d9bbc1538bd10ab2465688..a9e54f8d34998cdbf627695cdeb57ccc7d1f108b 100644 --- a/02VerketteteListe-2/Program.cs +++ b/02VerketteteListe-2/Program.cs @@ -2,7 +2,7 @@ using System.Collections; namespace _02VerketteteListe_2 -{ +{ class StringListe { // Die Klasse Element ist nun eine *private* Klasse der Klasse StringListe @@ -16,7 +16,7 @@ namespace _02VerketteteListe_2 public override string ToString() => name; } - Element anf=null, ende=null; + Element anf = null, ende = null; // int anz=0; //public StringListe() { } public void AddEnd(string name) @@ -100,6 +100,28 @@ namespace _02VerketteteListe_2 ende = vorletzter; } } + public void DeleteNth(int Ind) + { + // 1.Fall: Liste ist leer + // 2.Fall: Liste besteht nur aus einem Element UND Ind == 0 + // 3.Fall: Liste hat mehr als ein Element + // a) Ind==0 --> DeleteFront() + // b) Ind==max -> DeleteLast() + // c) Ind < max + if (anf == null) // 1. Fall + throw new NullReferenceException("Die Liste ist leer"); + if (anf == ende) // 2. Fall + anf = ende = null; + else // 3. Fall + { // Wir wissen: Die Liste hat mehr als ein Element, d.h. es gibt ein + // vorletztes Element vorletzter.next == ende + Element vorletzter = anf; + while (vorletzter.next != ende) + vorletzter = vorletzter.next; + vorletzter.next = null; + ende = vorletzter; + } + } } class Program { diff --git a/02VerketteteListe-2/bin/Debug/netcoreapp3.1/02VerketteteListe-2.dll b/02VerketteteListe-2/bin/Debug/netcoreapp3.1/02VerketteteListe-2.dll index 15a2faee77b089a2afdc40f066ca5fa13b4c7892..44e3e35231ed262d45ee44b10f88be888b339e5a 100644 Binary files a/02VerketteteListe-2/bin/Debug/netcoreapp3.1/02VerketteteListe-2.dll and b/02VerketteteListe-2/bin/Debug/netcoreapp3.1/02VerketteteListe-2.dll differ diff --git a/02VerketteteListe-2/bin/Debug/netcoreapp3.1/02VerketteteListe-2.pdb b/02VerketteteListe-2/bin/Debug/netcoreapp3.1/02VerketteteListe-2.pdb index 3baa29a36dd1896e1091a1554334687ea3d941b0..174d6740f21069322b211277327a0769559fad07 100644 Binary files a/02VerketteteListe-2/bin/Debug/netcoreapp3.1/02VerketteteListe-2.pdb and b/02VerketteteListe-2/bin/Debug/netcoreapp3.1/02VerketteteListe-2.pdb differ diff --git a/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.csprojAssemblyReference.cache b/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.csprojAssemblyReference.cache index a0fbfd12797557adefa2aaaacd9d5126dec64303..e23245258eaf6b6145a13830bacb66ca8fd7c885 100644 Binary files a/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.csprojAssemblyReference.cache and b/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.csprojAssemblyReference.cache differ diff --git a/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.dll b/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.dll index 15a2faee77b089a2afdc40f066ca5fa13b4c7892..44e3e35231ed262d45ee44b10f88be888b339e5a 100644 Binary files a/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.dll and b/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.dll differ diff --git a/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.pdb b/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.pdb index 3baa29a36dd1896e1091a1554334687ea3d941b0..174d6740f21069322b211277327a0769559fad07 100644 Binary files a/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.pdb and b/02VerketteteListe-2/obj/Debug/netcoreapp3.1/02VerketteteListe-2.pdb differ diff --git a/03 UebgMo FiFoListe/Program.cs b/03 UebgMo FiFoListe/Program.cs index c33377c28dc103f39c9502ffeecd5839ced3fc65..1e855e74eea5d87ba1da555f35ceda93d14230f3 100644 --- a/03 UebgMo FiFoListe/Program.cs +++ b/03 UebgMo FiFoListe/Program.cs @@ -1,4 +1,5 @@ using System; +using System.Collections; namespace _03_UebgMo_FiFoListe { @@ -7,7 +8,7 @@ namespace _03_UebgMo_FiFoListe class Element { public string name; - + public Element next; public Element(string name) { this.name = name; } public override string ToString() => name; @@ -16,7 +17,8 @@ namespace _03_UebgMo_FiFoListe int anz; public FiFoListe() { - + anf = ende = null; + anz = 0; } /// <summary> /// Fügt der Warteschlange ein neues Element hinzu @@ -24,7 +26,15 @@ namespace _03_UebgMo_FiFoListe /// <param name="text"></param> public void Push(string text) { - + Element neu = new Element(text); + anz++; + if (anf == null) + anf = ende = neu; + else + { + ende.next = neu; + ende = neu; + } } /// <summary> /// @@ -32,7 +42,8 @@ namespace _03_UebgMo_FiFoListe /// <param name="textFeld"></param> public void Push(params string[] textFeld) { - + foreach (string item in textFeld) + Push(item); } /// <summary> /// Liefert das erste Element zurück. Es bleibt aber in der Warteschlange @@ -40,7 +51,10 @@ namespace _03_UebgMo_FiFoListe /// <returns></returns> public string First() { - + if(anf== null) + throw new ArgumentNullException("Leere Warteschlange"); + else + return anf.name; } /// <summary> /// Liefert Wert des ersten Ausgabeelements zurück UND entfernt dieses aus der Warteschlange @@ -51,14 +65,25 @@ namespace _03_UebgMo_FiFoListe // 1.Fall: Liste ist leer // 2.Fall: Liste besteht nur aus *einem* Element // 3.Fall: Liste hat mehr als ein Element - + if (anf == null) + throw new ArgumentNullException("Liste ist leer"); + string erg = anf.name; + if (anf == ende) + anf = ende = null; + else + anf = anf.next; + anz--; + return erg; } /// <summary> /// Gibt alle Elemente der Warteschlange auf dem Bildschirm aus /// </summary> public void WriteAll() { - + for (Element item = anf; item != null; item = item.next) + { + Console.WriteLine(item); + } } /// <summary> /// liefert ein string-Feld mit allen gespeicherten Elementen zurück; @@ -67,12 +92,28 @@ namespace _03_UebgMo_FiFoListe /// <returns></returns> public string[] GetAll() { - + if (anz == 0) + return null; + string[] erg = new string[anz]; + int i = 0; + for (Element tmp = anf; tmp != null; tmp = tmp.next) + { + erg[i] = tmp.name; + i++; + } + return erg; + } + public IEnumerator GetEnumerator() + { + for (Element tmp = anf; tmp != null; tmp = tmp.next) + { + yield return tmp.name; + } } /// <summary> /// Anzahl der Elemente in der Warteschlange zurückgeben /// </summary> - public int ItemCount { } + public int ItemCount { get => anz; } } class Program @@ -95,6 +136,10 @@ namespace _03_UebgMo_FiFoListe { Console.WriteLine($"foreach: {item}"); } + foreach (string item in f) + { + Console.WriteLine($"GetEnumerator: {item}"); + } } } } diff --git a/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.deps.json b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.deps.json new file mode 100644 index 0000000000000000000000000000000000000000..b9d18d7ec37d4e3306a7bf6a0f1ee1c1d508f638 --- /dev/null +++ b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.deps.json @@ -0,0 +1,23 @@ +{ + "runtimeTarget": { + "name": ".NETCoreApp,Version=v3.1", + "signature": "" + }, + "compilationOptions": {}, + "targets": { + ".NETCoreApp,Version=v3.1": { + "03 UebgMo FiFoListe/1.0.0": { + "runtime": { + "03 UebgMo FiFoListe.dll": {} + } + } + } + }, + "libraries": { + "03 UebgMo FiFoListe/1.0.0": { + "type": "project", + "serviceable": false, + "sha512": "" + } + } +} \ No newline at end of file diff --git a/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.dll b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.dll new file mode 100644 index 0000000000000000000000000000000000000000..0a74addb5f8c7c43842e478fd05f0ab171fe93b6 Binary files /dev/null and b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.dll differ diff --git a/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.exe b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.exe new file mode 100644 index 0000000000000000000000000000000000000000..d7924022ff97855f0271f0606d7805498cb977d5 Binary files /dev/null and b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.exe differ diff --git a/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.pdb b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.pdb new file mode 100644 index 0000000000000000000000000000000000000000..c118e716987db7d82260bcfc9bcd2f7272f72201 Binary files /dev/null and b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.pdb differ diff --git a/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.runtimeconfig.dev.json b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.runtimeconfig.dev.json new file mode 100644 index 0000000000000000000000000000000000000000..3becea41545888f98131d88ad51766e8ddde3bce --- /dev/null +++ b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.runtimeconfig.dev.json @@ -0,0 +1,8 @@ +{ + "runtimeOptions": { + "additionalProbingPaths": [ + "C:\\Users\\wienkop\\.dotnet\\store\\|arch|\\|tfm|", + "C:\\Users\\wienkop\\.nuget\\packages" + ] + } +} \ No newline at end of file diff --git a/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.runtimeconfig.json b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.runtimeconfig.json new file mode 100644 index 0000000000000000000000000000000000000000..bc456d7868bb54ec1809da30e339cd43f0a8a09c --- /dev/null +++ b/03 UebgMo FiFoListe/bin/Debug/netcoreapp3.1/03 UebgMo FiFoListe.runtimeconfig.json @@ -0,0 +1,9 @@ +{ + "runtimeOptions": { + "tfm": "netcoreapp3.1", + "framework": { + "name": "Microsoft.NETCore.App", + "version": "3.1.0" + } + } +} \ No newline at end of file diff --git a/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.csproj.CoreCompileInputs.cache b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.csproj.CoreCompileInputs.cache new file mode 100644 index 0000000000000000000000000000000000000000..866b744e18d17bd43f4fc4b66cbb3dbc817b1992 --- /dev/null +++ b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.csproj.CoreCompileInputs.cache @@ -0,0 +1 @@ +c0523642d3f3714f80c0cf31b3f8720f51a0bc09 diff --git a/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.csproj.FileListAbsolute.txt b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.csproj.FileListAbsolute.txt new file mode 100644 index 0000000000000000000000000000000000000000..c67662dc45f43548bb94eb776ae34139f9ad754e --- /dev/null +++ b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.csproj.FileListAbsolute.txt @@ -0,0 +1,12 @@ +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\obj\Debug\netcoreapp3.1\03 UebgMo FiFoListe.csproj.CoreCompileInputs.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\obj\Debug\netcoreapp3.1\03 UebgMo FiFoListe.AssemblyInfoInputs.cache +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\obj\Debug\netcoreapp3.1\03 UebgMo FiFoListe.AssemblyInfo.cs +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\bin\Debug\netcoreapp3.1\03 UebgMo FiFoListe.exe +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\bin\Debug\netcoreapp3.1\03 UebgMo FiFoListe.deps.json +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\bin\Debug\netcoreapp3.1\03 UebgMo FiFoListe.runtimeconfig.json +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\bin\Debug\netcoreapp3.1\03 UebgMo FiFoListe.runtimeconfig.dev.json +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\bin\Debug\netcoreapp3.1\03 UebgMo FiFoListe.dll +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\bin\Debug\netcoreapp3.1\03 UebgMo FiFoListe.pdb +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\obj\Debug\netcoreapp3.1\03 UebgMo FiFoListe.dll +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\obj\Debug\netcoreapp3.1\03 UebgMo FiFoListe.pdb +C:\Users\wienkop\source\repos\prog2-ss2020-wienkop\03 UebgMo FiFoListe\obj\Debug\netcoreapp3.1\03 UebgMo FiFoListe.genruntimeconfig.cache diff --git a/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.dll b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.dll new file mode 100644 index 0000000000000000000000000000000000000000..0a74addb5f8c7c43842e478fd05f0ab171fe93b6 Binary files /dev/null and b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.dll differ diff --git a/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.exe b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.exe new file mode 100644 index 0000000000000000000000000000000000000000..d7924022ff97855f0271f0606d7805498cb977d5 Binary files /dev/null and b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.exe differ diff --git a/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.genruntimeconfig.cache b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.genruntimeconfig.cache new file mode 100644 index 0000000000000000000000000000000000000000..34bedab819ef1631d37d6e87ef9a716c545a105e --- /dev/null +++ b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.genruntimeconfig.cache @@ -0,0 +1 @@ +86c8e15dd33445635927cfaf398408205fd11473 diff --git a/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.pdb b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.pdb new file mode 100644 index 0000000000000000000000000000000000000000..c118e716987db7d82260bcfc9bcd2f7272f72201 Binary files /dev/null and b/03 UebgMo FiFoListe/obj/Debug/netcoreapp3.1/03 UebgMo FiFoListe.pdb differ