diff --git a/20240912_doga/Dolgozat.pdf b/20240912_doga/Dolgozat.pdf new file mode 100644 index 0000000..2cd86dc Binary files /dev/null and b/20240912_doga/Dolgozat.pdf differ diff --git a/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/FileContentIndex/9bcedf5b-794e-4adf-9622-93429220f78a.vsidx b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/FileContentIndex/9bcedf5b-794e-4adf-9622-93429220f78a.vsidx new file mode 100644 index 0000000..70aef67 Binary files /dev/null and b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/FileContentIndex/9bcedf5b-794e-4adf-9622-93429220f78a.vsidx differ diff --git a/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/FileContentIndex/ad1199d9-6e66-4412-9ba9-2df31568ec6e.vsidx b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/FileContentIndex/ad1199d9-6e66-4412-9ba9-2df31568ec6e.vsidx new file mode 100644 index 0000000..70aef67 Binary files /dev/null and b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/FileContentIndex/ad1199d9-6e66-4412-9ba9-2df31568ec6e.vsidx differ diff --git a/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/FileContentIndex/ebb342dc-204c-4ad5-b0e0-00ad61baed5c.vsidx b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/FileContentIndex/ebb342dc-204c-4ad5-b0e0-00ad61baed5c.vsidx new file mode 100644 index 0000000..ad3f6da Binary files /dev/null and b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/FileContentIndex/ebb342dc-204c-4ad5-b0e0-00ad61baed5c.vsidx differ diff --git a/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/v17/DocumentLayout.backup.json b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/v17/DocumentLayout.backup.json index a024549..c818eda 100644 --- a/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/v17/DocumentLayout.backup.json +++ b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/v17/DocumentLayout.backup.json @@ -1,13 +1,13 @@ { "Version": 1, - "WorkspaceRootPath": "S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\", + "WorkspaceRootPath": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\", "Documents": [ { - "AbsoluteMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|s:\\programoz\u00E1s_dolgozat\\szab\u00F3m\u00E1rton_20240912\\maratonvaltogui\\maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", + "AbsoluteMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|c:\\users\\szabomarton\\desktop\\progaora\\20240912_doga\\maratonvaltogui\\maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", "RelativeMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|solutionrelative:maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}" }, { - "AbsoluteMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form", + "AbsoluteMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form", "RelativeMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|solutionrelative:maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form" } ], @@ -24,11 +24,11 @@ "$type": "Document", "DocumentIndex": 0, "Title": "Form1.cs", - "DocumentMoniker": "S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", "RelativeDocumentMoniker": "MaratonValtoGUI\\Form1.cs", - "ToolTip": "S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", "RelativeToolTip": "MaratonValtoGUI\\Form1.cs", - "ViewState": "AgIAAFEAAAAAAAAAAAAAwGMAAAAjAAAAAAAAAA==", + "ViewState": "AgIAAF4AAAAAAAAAAAAawGIAAAAAAAAAAAAAAA==", "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", "WhenOpened": "2024-09-12T07:43:09.212Z", "EditorCaption": "" @@ -37,11 +37,13 @@ "$type": "Document", "DocumentIndex": 1, "Title": "Form1.cs [Design]", - "DocumentMoniker": "S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", "RelativeDocumentMoniker": "MaratonValtoGUI\\Form1.cs", - "ToolTip": "C:\\Users\\szabomarton\\Desktop\\C#\\Dolgozat\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs [Design]", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs [Design]", + "RelativeToolTip": "MaratonValtoGUI\\Form1.cs [Design]", "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", - "WhenOpened": "2024-09-12T07:39:37.232Z" + "WhenOpened": "2024-09-12T07:39:37.232Z", + "EditorCaption": " [Design]" } ] } diff --git a/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/v17/DocumentLayout.json b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/v17/DocumentLayout.json index a024549..c818eda 100644 --- a/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/v17/DocumentLayout.json +++ b/20240912_doga/MaratonValtoGUI/.vs/MaratonValtoGUI/v17/DocumentLayout.json @@ -1,13 +1,13 @@ { "Version": 1, - "WorkspaceRootPath": "S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\", + "WorkspaceRootPath": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\", "Documents": [ { - "AbsoluteMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|s:\\programoz\u00E1s_dolgozat\\szab\u00F3m\u00E1rton_20240912\\maratonvaltogui\\maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", + "AbsoluteMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|c:\\users\\szabomarton\\desktop\\progaora\\20240912_doga\\maratonvaltogui\\maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", "RelativeMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|solutionrelative:maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}" }, { - "AbsoluteMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form", + "AbsoluteMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form", "RelativeMoniker": "D:0:0:{F1F2A2F9-D38C-404A-AC20-237C68980382}|MaratonValtoGUI\\MaratonValtoGUI.csproj|solutionrelative:maratonvaltogui\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form" } ], @@ -24,11 +24,11 @@ "$type": "Document", "DocumentIndex": 0, "Title": "Form1.cs", - "DocumentMoniker": "S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", "RelativeDocumentMoniker": "MaratonValtoGUI\\Form1.cs", - "ToolTip": "S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", "RelativeToolTip": "MaratonValtoGUI\\Form1.cs", - "ViewState": "AgIAAFEAAAAAAAAAAAAAwGMAAAAjAAAAAAAAAA==", + "ViewState": "AgIAAF4AAAAAAAAAAAAawGIAAAAAAAAAAAAAAA==", "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", "WhenOpened": "2024-09-12T07:43:09.212Z", "EditorCaption": "" @@ -37,11 +37,13 @@ "$type": "Document", "DocumentIndex": 1, "Title": "Form1.cs [Design]", - "DocumentMoniker": "S:\\Programoz\u00E1s_dolgozat\\Szab\u00F3M\u00E1rton_20240912\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs", "RelativeDocumentMoniker": "MaratonValtoGUI\\Form1.cs", - "ToolTip": "C:\\Users\\szabomarton\\Desktop\\C#\\Dolgozat\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs [Design]", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\ProgaOra\\20240912_doga\\MaratonValtoGUI\\MaratonValtoGUI\\Form1.cs [Design]", + "RelativeToolTip": "MaratonValtoGUI\\Form1.cs [Design]", "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", - "WhenOpened": "2024-09-12T07:39:37.232Z" + "WhenOpened": "2024-09-12T07:39:37.232Z", + "EditorCaption": " [Design]" } ] } diff --git a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/Form1.cs b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/Form1.cs index ce3cde3..5cff1a5 100644 --- a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/Form1.cs +++ b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/Form1.cs @@ -20,12 +20,8 @@ namespace MaratonValtoGUI public void Form1_Load(object sender, EventArgs e) { - Data.eredmenyek = LoadFromCsv("maratonvalto.csv"); - foreach (var item in Data.eredmenyek) - { - listBox1.Items.Add(item.Versenyzo.Fnev); - } + } @@ -33,6 +29,17 @@ namespace MaratonValtoGUI private void megnyitásToolStripMenuItem_Click(object sender, EventArgs e) { //string filepath = OpenFileDialog(); + OpenFileDialog openFileDialog = new OpenFileDialog(); + openFileDialog.ShowDialog(); + + string path = openFileDialog.FileName; + + Data.eredmenyek = LoadFromCsv(path); + + foreach (var item in Data.eredmenyek) + { + listBox1.Items.Add(item.Versenyzo.Fnev); + } } private void kiléToolStripMenuItem_Click(object sender, EventArgs e) diff --git a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/bin/Debug/MaratonValtoGUI.exe b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/bin/Debug/MaratonValtoGUI.exe index c2c2068..1c274a4 100644 Binary files a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/bin/Debug/MaratonValtoGUI.exe and b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/bin/Debug/MaratonValtoGUI.exe differ diff --git a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/bin/Debug/MaratonValtoGUI.pdb b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/bin/Debug/MaratonValtoGUI.pdb index b2e60c7..98b72e5 100644 Binary files a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/bin/Debug/MaratonValtoGUI.pdb and b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/bin/Debug/MaratonValtoGUI.pdb differ diff --git a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/DesignTimeResolveAssemblyReferences.cache b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/DesignTimeResolveAssemblyReferences.cache index 3f579a2..2d21f8d 100644 Binary files a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/DesignTimeResolveAssemblyReferences.cache and b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/DesignTimeResolveAssemblyReferences.cache differ diff --git a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.csproj.FileListAbsolute.txt b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.csproj.FileListAbsolute.txt index 392de2f..db174a4 100644 --- a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.csproj.FileListAbsolute.txt +++ b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.csproj.FileListAbsolute.txt @@ -8,3 +8,13 @@ C:\Users\szabomarton\Desktop\C#\Dolgozat\MaratonValtoGUI\MaratonValtoGUI\obj\Deb C:\Users\szabomarton\Desktop\C#\Dolgozat\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.csproj.CoreCompileInputs.cache C:\Users\szabomarton\Desktop\C#\Dolgozat\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.exe C:\Users\szabomarton\Desktop\C#\Dolgozat\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.pdb +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\bin\Debug\MaratonValtoGUI.exe.config +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\bin\Debug\MaratonValtoGUI.exe +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\bin\Debug\MaratonValtoGUI.pdb +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.csproj.AssemblyReference.cache +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.Form1.resources +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.Properties.Resources.resources +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.csproj.GenerateResource.cache +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.csproj.CoreCompileInputs.cache +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.exe +C:\Users\szabomarton\Desktop\ProgaOra\20240912_doga\MaratonValtoGUI\MaratonValtoGUI\obj\Debug\MaratonValtoGUI.pdb diff --git a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.exe b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.exe index c2c2068..1c274a4 100644 Binary files a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.exe and b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.exe differ diff --git a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.pdb b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.pdb index b2e60c7..98b72e5 100644 Binary files a/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.pdb and b/20240912_doga/MaratonValtoGUI/MaratonValtoGUI/obj/Debug/MaratonValtoGUI.pdb differ diff --git a/20240919/ConsoleApp1/.vs/ConsoleApp1/FileContentIndex/3229a0d1-a622-465c-88bf-b6c7c6ea2038.vsidx b/20240919/ConsoleApp1/.vs/ConsoleApp1/FileContentIndex/3229a0d1-a622-465c-88bf-b6c7c6ea2038.vsidx new file mode 100644 index 0000000..415afca Binary files /dev/null and b/20240919/ConsoleApp1/.vs/ConsoleApp1/FileContentIndex/3229a0d1-a622-465c-88bf-b6c7c6ea2038.vsidx differ diff --git a/20240919/ConsoleApp1/.vs/ConsoleApp1/v17/.suo b/20240919/ConsoleApp1/.vs/ConsoleApp1/v17/.suo new file mode 100644 index 0000000..c0e4bdb Binary files /dev/null and b/20240919/ConsoleApp1/.vs/ConsoleApp1/v17/.suo differ diff --git a/20240919/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.backup.json b/20240919/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.backup.json new file mode 100644 index 0000000..ad977d0 --- /dev/null +++ b/20240919/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.backup.json @@ -0,0 +1,37 @@ +{ + "Version": 1, + "WorkspaceRootPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240919\\ConsoleApp1\\", + "Documents": [ + { + "AbsoluteMoniker": "D:0:0:{36A44E1B-CB62-446B-86E4-AA211A1C4DFD}|ConsoleApp1\\ConsoleApp1.csproj|c:\\users\\szabomarton\\desktop\\c#\\progaora\\20240919\\consoleapp1\\consoleapp1\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", + "RelativeMoniker": "D:0:0:{36A44E1B-CB62-446B-86E4-AA211A1C4DFD}|ConsoleApp1\\ConsoleApp1.csproj|solutionrelative:consoleapp1\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}" + } + ], + "DocumentGroupContainers": [ + { + "Orientation": 0, + "VerticalTabListWidth": 256, + "DocumentGroups": [ + { + "DockedWidth": 200, + "SelectedChildIndex": 0, + "Children": [ + { + "$type": "Document", + "DocumentIndex": 0, + "Title": "Program.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240919\\ConsoleApp1\\ConsoleApp1\\Program.cs", + "RelativeDocumentMoniker": "ConsoleApp1\\Program.cs", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240919\\ConsoleApp1\\ConsoleApp1\\Program.cs", + "RelativeToolTip": "ConsoleApp1\\Program.cs", + "ViewState": "AgIAADEAAAAAAAAAAAAcwEMAAAAAAAAAAAAAAA==", + "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", + "WhenOpened": "2024-09-19T06:52:49.159Z", + "EditorCaption": "" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/20240919/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.json b/20240919/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.json new file mode 100644 index 0000000..9dc5e4d --- /dev/null +++ b/20240919/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.json @@ -0,0 +1,41 @@ +{ + "Version": 1, + "WorkspaceRootPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240919\\ConsoleApp1\\", + "Documents": [ + { + "AbsoluteMoniker": "D:0:0:{36A44E1B-CB62-446B-86E4-AA211A1C4DFD}|ConsoleApp1\\ConsoleApp1.csproj|c:\\users\\szabomarton\\desktop\\c#\\progaora\\20240919\\consoleapp1\\consoleapp1\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", + "RelativeMoniker": "D:0:0:{36A44E1B-CB62-446B-86E4-AA211A1C4DFD}|ConsoleApp1\\ConsoleApp1.csproj|solutionrelative:consoleapp1\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}" + } + ], + "DocumentGroupContainers": [ + { + "Orientation": 0, + "VerticalTabListWidth": 256, + "DocumentGroups": [ + { + "DockedWidth": 200, + "SelectedChildIndex": 0, + "Children": [ + { + "$type": "Document", + "DocumentIndex": 0, + "Title": "Program.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240919\\ConsoleApp1\\ConsoleApp1\\Program.cs", + "RelativeDocumentMoniker": "ConsoleApp1\\Program.cs", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240919\\ConsoleApp1\\ConsoleApp1\\Program.cs", + "RelativeToolTip": "ConsoleApp1\\Program.cs", + "ViewState": "AgIAADEAAAAAAAAAAAAcwFwAAAAyAAAAAAAAAA==", + "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", + "WhenOpened": "2024-09-19T06:52:49.159Z", + "EditorCaption": "" + }, + { + "$type": "Bookmark", + "Name": "ST:0:0:{cce594b6-0c39-4442-ba28-10c64ac7e89f}" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/20240919/ConsoleApp1/ConsoleApp1.sln b/20240919/ConsoleApp1/ConsoleApp1.sln new file mode 100644 index 0000000..30b248b --- /dev/null +++ b/20240919/ConsoleApp1/ConsoleApp1.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.11.35222.181 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ConsoleApp1", "ConsoleApp1\ConsoleApp1.csproj", "{36A44E1B-CB62-446B-86E4-AA211A1C4DFD}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {36A44E1B-CB62-446B-86E4-AA211A1C4DFD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {36A44E1B-CB62-446B-86E4-AA211A1C4DFD}.Debug|Any CPU.Build.0 = Debug|Any CPU + {36A44E1B-CB62-446B-86E4-AA211A1C4DFD}.Release|Any CPU.ActiveCfg = Release|Any CPU + {36A44E1B-CB62-446B-86E4-AA211A1C4DFD}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {AEBD4DC6-C386-4383-A868-204B9E548812} + EndGlobalSection +EndGlobal diff --git a/20240919/ConsoleApp1/ConsoleApp1/App.config b/20240919/ConsoleApp1/ConsoleApp1/App.config new file mode 100644 index 0000000..56efbc7 --- /dev/null +++ b/20240919/ConsoleApp1/ConsoleApp1/App.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/20240919/ConsoleApp1/ConsoleApp1/ConsoleApp1.csproj b/20240919/ConsoleApp1/ConsoleApp1/ConsoleApp1.csproj new file mode 100644 index 0000000..57bf964 --- /dev/null +++ b/20240919/ConsoleApp1/ConsoleApp1/ConsoleApp1.csproj @@ -0,0 +1,53 @@ + + + + + Debug + AnyCPU + {36A44E1B-CB62-446B-86E4-AA211A1C4DFD} + Exe + ConsoleApp1 + ConsoleApp1 + v4.7.2 + 512 + true + true + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/20240919/ConsoleApp1/ConsoleApp1/Program.cs b/20240919/ConsoleApp1/ConsoleApp1/Program.cs new file mode 100644 index 0000000..fe55c9c --- /dev/null +++ b/20240919/ConsoleApp1/ConsoleApp1/Program.cs @@ -0,0 +1,131 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.IO; +using System.Diagnostics.Tracing; +using System.Diagnostics.Contracts; +using System.Runtime.CompilerServices; + +namespace ConsoleApp1 +{ + internal class Program + { + static void Main(string[] args) + { + DataRead("C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240919\\termekek.csv", ';'); + //Feladat1(); + Feladat2(); + Feladat3(); + Feladat4(); + + Console.ReadLine(); + } + + static void Feladat1() + { + int fizetes_sum = Fizetes_SUM(Data.alkalmazottak); + double fizetes_avg = Fizetes_AVG(Data.alkalmazottak); + Console.WriteLine($"A fizetések összege: {fizetes_sum}"); + Console.WriteLine($"A fizetések Átlaga: {fizetes_avg:F2}"); + } + + static int Fizetes_SUM(List T) { + var result = T.Select(x => x.fizetes); + return result.Sum(); + } + + static double Fizetes_AVG(List T) + { + IEnumerable asd = T.Select(x => x.fizetes); + return asd.Average(); + } + + static void Feladat2() + { + foreach (var item in Data.raktar) + { + Console.WriteLine($"{item.nev}"); + } + } + + static void Feladat3() + { + var result = Data.raktar.GroupBy(y => y.kategoria).Select(x => new {x.Key, darab = x.Count()}); + foreach (var item in result) + { + Console.WriteLine($"{item.Key} {item.darab}"); + } + + } + + static void Feladat4() + { + var legolcsobb = Data.raktar.OrderBy(x => x.ar).Select(y => new {y.nev, y.ar}); + Console.WriteLine(legolcsobb); + } + + + static void DataRead(string path, char splitchar) + { + using (StreamReader streamReader = new StreamReader(path)) + { + string line = streamReader.ReadLine(); + line = streamReader.ReadLine(); + while (line != null) + { + string[] datas = line.Split(splitchar); + + TermekAdd(datas); + + line = streamReader.ReadLine(); + } + } + } + + static void TermekAdd(string[] datas) + { + Termek termek = new Termek(datas[0], datas[1], Int32.Parse(datas[2])); + Data.raktar.Add(termek); + } + + static void AlkalmazottAdd(string[] datas) + { + Alkalmazott alkalmazott = new Alkalmazott(datas[0], Int32.Parse(datas[1])); + Data.alkalmazottak.Add(alkalmazott); + } + } + + public class Alkalmazott + { + public string nev; + public int fizetes; + + public Alkalmazott(string Nev, int Fizetes) + { + nev = Nev; + fizetes = Fizetes; + } + } + + public class Termek + { + public string nev; + public string kategoria; + public int ar; + + public Termek(string Nev, string Kategoria, int Ar) + { + nev = Nev; + kategoria = Kategoria; + ar = Ar; + } + } + + public static class Data + { + public static List alkalmazottak = new List (); + public static List raktar = new List (); + } +} diff --git a/20240919/ConsoleApp1/ConsoleApp1/Properties/AssemblyInfo.cs b/20240919/ConsoleApp1/ConsoleApp1/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..a699f02 --- /dev/null +++ b/20240919/ConsoleApp1/ConsoleApp1/Properties/AssemblyInfo.cs @@ -0,0 +1,33 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("ConsoleApp1")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("ConsoleApp1")] +[assembly: AssemblyCopyright("Copyright © 2024")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("36a44e1b-cb62-446b-86e4-aa211a1c4dfd")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/20240919/ConsoleApp1/ConsoleApp1/bin/Debug/ConsoleApp1.exe b/20240919/ConsoleApp1/ConsoleApp1/bin/Debug/ConsoleApp1.exe new file mode 100644 index 0000000..35bb8ba Binary files /dev/null and b/20240919/ConsoleApp1/ConsoleApp1/bin/Debug/ConsoleApp1.exe differ diff --git a/20240919/ConsoleApp1/ConsoleApp1/bin/Debug/ConsoleApp1.exe.config b/20240919/ConsoleApp1/ConsoleApp1/bin/Debug/ConsoleApp1.exe.config new file mode 100644 index 0000000..56efbc7 --- /dev/null +++ b/20240919/ConsoleApp1/ConsoleApp1/bin/Debug/ConsoleApp1.exe.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/20240919/ConsoleApp1/ConsoleApp1/bin/Debug/ConsoleApp1.pdb b/20240919/ConsoleApp1/ConsoleApp1/bin/Debug/ConsoleApp1.pdb new file mode 100644 index 0000000..874dca3 Binary files /dev/null and b/20240919/ConsoleApp1/ConsoleApp1/bin/Debug/ConsoleApp1.pdb differ diff --git a/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/.NETFramework,Version=v4.7.2.AssemblyAttributes.cs b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/.NETFramework,Version=v4.7.2.AssemblyAttributes.cs new file mode 100644 index 0000000..3871b18 --- /dev/null +++ b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/.NETFramework,Version=v4.7.2.AssemblyAttributes.cs @@ -0,0 +1,4 @@ +// +using System; +using System.Reflection; +[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")] diff --git a/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.csproj.AssemblyReference.cache b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.csproj.AssemblyReference.cache new file mode 100644 index 0000000..126ed02 Binary files /dev/null and b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.csproj.AssemblyReference.cache differ diff --git a/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.csproj.CoreCompileInputs.cache b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.csproj.CoreCompileInputs.cache new file mode 100644 index 0000000..0be8d26 --- /dev/null +++ b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.csproj.CoreCompileInputs.cache @@ -0,0 +1 @@ +137ddb1975586287657f37337b64d051167bb6a147915d9fb5b8eb94b1093509 diff --git a/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.csproj.FileListAbsolute.txt b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.csproj.FileListAbsolute.txt new file mode 100644 index 0000000..aabaa8f --- /dev/null +++ b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.csproj.FileListAbsolute.txt @@ -0,0 +1,7 @@ +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240919\ConsoleApp1\ConsoleApp1\bin\Debug\ConsoleApp1.exe.config +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240919\ConsoleApp1\ConsoleApp1\bin\Debug\ConsoleApp1.exe +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240919\ConsoleApp1\ConsoleApp1\bin\Debug\ConsoleApp1.pdb +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240919\ConsoleApp1\ConsoleApp1\obj\Debug\ConsoleApp1.csproj.AssemblyReference.cache +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240919\ConsoleApp1\ConsoleApp1\obj\Debug\ConsoleApp1.csproj.CoreCompileInputs.cache +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240919\ConsoleApp1\ConsoleApp1\obj\Debug\ConsoleApp1.exe +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240919\ConsoleApp1\ConsoleApp1\obj\Debug\ConsoleApp1.pdb diff --git a/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.exe b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.exe new file mode 100644 index 0000000..35bb8ba Binary files /dev/null and b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.exe differ diff --git a/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.pdb b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.pdb new file mode 100644 index 0000000..874dca3 Binary files /dev/null and b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/ConsoleApp1.pdb differ diff --git a/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache new file mode 100644 index 0000000..0b9a7af Binary files /dev/null and b/20240919/ConsoleApp1/ConsoleApp1/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache differ diff --git a/20240919/alkalmazottak.txt b/20240919/alkalmazottak.txt new file mode 100644 index 0000000..a0a77dd --- /dev/null +++ b/20240919/alkalmazottak.txt @@ -0,0 +1,18 @@ +Név,Fizetés +Kiss Péter,300000 +Nagy László,400000 +Szabó Erika,350000 +Tóth Gábor,500000 +Molnár András,280000 +Varga Judit,450000 +Farkas Béla,370000 +Balogh Ágnes,330000 +Kovács Dóra,380000 +Boros Anikó,410000 +Lukács Gábor,430000 +Horváth István,295000 +Vörös Anna,310000 +Veres Katalin,470000 +Fekete Csaba,440000 +Fehér Levente,360000 +Simon László,300000 diff --git a/20240919/termekek.csv b/20240919/termekek.csv new file mode 100644 index 0000000..403cd2d --- /dev/null +++ b/20240919/termekek.csv @@ -0,0 +1,18 @@ +Név;Kategória;Ár +Laptop;Elektronikai eszközök;900000 +Egér;Elektronikai eszközök;2000 +Szék;Bútorok;50000 +Asztal;Bútorok;150000 +Ceruza;Irodai eszközök;200 +Nyomtató;Elektronikai eszközök;30000 +Toll;Irodai eszközök;300 +Polc;Bútorok;10000 +Lámpa;Bútorok;7000 +Hűtőszekrény;Elektronikai eszközök;120000 +Tűzőgép;Irodai eszközök;800 +Számítógép;Elektronikai eszközök;150000 +Fotel;Bútorok;20000 +Papír;Irodai eszközök;100 +Tányér;Konyhai eszközök;5000 +Bögre;Konyhai eszközök;600 +Serpenyő;Konyhai eszközök;4000 diff --git a/20240920/ConsoleApp1/.vs/ConsoleApp1/DesignTimeBuild/.dtbcache.v2 b/20240920/ConsoleApp1/.vs/ConsoleApp1/DesignTimeBuild/.dtbcache.v2 new file mode 100644 index 0000000..6d5b335 Binary files /dev/null and b/20240920/ConsoleApp1/.vs/ConsoleApp1/DesignTimeBuild/.dtbcache.v2 differ diff --git a/20240920/ConsoleApp1/.vs/ConsoleApp1/FileContentIndex/1abc038d-60e5-42ea-b4b9-b843bac4fe07.vsidx b/20240920/ConsoleApp1/.vs/ConsoleApp1/FileContentIndex/1abc038d-60e5-42ea-b4b9-b843bac4fe07.vsidx new file mode 100644 index 0000000..10f5269 Binary files /dev/null and b/20240920/ConsoleApp1/.vs/ConsoleApp1/FileContentIndex/1abc038d-60e5-42ea-b4b9-b843bac4fe07.vsidx differ diff --git a/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/.futdcache.v2 b/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/.futdcache.v2 new file mode 100644 index 0000000..f30fb4f Binary files /dev/null and b/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/.futdcache.v2 differ diff --git a/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/.suo b/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/.suo new file mode 100644 index 0000000..044720a Binary files /dev/null and b/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/.suo differ diff --git a/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.backup.json b/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.backup.json new file mode 100644 index 0000000..44bcb93 --- /dev/null +++ b/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.backup.json @@ -0,0 +1,41 @@ +{ + "Version": 1, + "WorkspaceRootPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\", + "Documents": [ + { + "AbsoluteMoniker": "D:0:0:{712B1E33-47B9-442C-B7A2-A5DD3FCFA1DB}|ConsoleApp1\\ConsoleApp1.csproj|c:\\users\\szabomarton\\desktop\\c#\\progaora\\20240920\\consoleapp1\\consoleapp1\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", + "RelativeMoniker": "D:0:0:{712B1E33-47B9-442C-B7A2-A5DD3FCFA1DB}|ConsoleApp1\\ConsoleApp1.csproj|solutionrelative:consoleapp1\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}" + } + ], + "DocumentGroupContainers": [ + { + "Orientation": 0, + "VerticalTabListWidth": 256, + "DocumentGroups": [ + { + "DockedWidth": 200, + "SelectedChildIndex": 1, + "Children": [ + { + "$type": "Bookmark", + "Name": "ST:0:0:{cce594b6-0c39-4442-ba28-10c64ac7e89f}" + }, + { + "$type": "Document", + "DocumentIndex": 0, + "Title": "Program.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\Program.cs", + "RelativeDocumentMoniker": "ConsoleApp1\\Program.cs", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\Program.cs", + "RelativeToolTip": "ConsoleApp1\\Program.cs", + "ViewState": "AgIAAAAAAAAAAAAAAAAAAAwAAAAIAAAAAAAAAA==", + "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", + "WhenOpened": "2024-09-20T07:54:27.77Z", + "EditorCaption": "" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.json b/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.json new file mode 100644 index 0000000..42e3182 --- /dev/null +++ b/20240920/ConsoleApp1/.vs/ConsoleApp1/v17/DocumentLayout.json @@ -0,0 +1,41 @@ +{ + "Version": 1, + "WorkspaceRootPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\", + "Documents": [ + { + "AbsoluteMoniker": "D:0:0:{712B1E33-47B9-442C-B7A2-A5DD3FCFA1DB}|ConsoleApp1\\ConsoleApp1.csproj|c:\\users\\szabomarton\\desktop\\c#\\progaora\\20240920\\consoleapp1\\consoleapp1\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", + "RelativeMoniker": "D:0:0:{712B1E33-47B9-442C-B7A2-A5DD3FCFA1DB}|ConsoleApp1\\ConsoleApp1.csproj|solutionrelative:consoleapp1\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}" + } + ], + "DocumentGroupContainers": [ + { + "Orientation": 0, + "VerticalTabListWidth": 256, + "DocumentGroups": [ + { + "DockedWidth": 200, + "SelectedChildIndex": 1, + "Children": [ + { + "$type": "Bookmark", + "Name": "ST:0:0:{cce594b6-0c39-4442-ba28-10c64ac7e89f}" + }, + { + "$type": "Document", + "DocumentIndex": 0, + "Title": "Program.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\Program.cs", + "RelativeDocumentMoniker": "ConsoleApp1\\Program.cs", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\Program.cs", + "RelativeToolTip": "ConsoleApp1\\Program.cs", + "ViewState": "AgIAACUAAAAAAAAAAAA9wEkAAAAAAAAAAAAAAA==", + "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", + "WhenOpened": "2024-09-20T07:54:27.77Z", + "EditorCaption": "" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/20240920/ConsoleApp1/.vs/ProjectEvaluation/consoleapp1.metadata.v9.bin b/20240920/ConsoleApp1/.vs/ProjectEvaluation/consoleapp1.metadata.v9.bin new file mode 100644 index 0000000..f0563bf Binary files /dev/null and b/20240920/ConsoleApp1/.vs/ProjectEvaluation/consoleapp1.metadata.v9.bin differ diff --git a/20240920/ConsoleApp1/.vs/ProjectEvaluation/consoleapp1.projects.v9.bin b/20240920/ConsoleApp1/.vs/ProjectEvaluation/consoleapp1.projects.v9.bin new file mode 100644 index 0000000..995a4b1 Binary files /dev/null and b/20240920/ConsoleApp1/.vs/ProjectEvaluation/consoleapp1.projects.v9.bin differ diff --git a/20240920/ConsoleApp1/.vs/ProjectEvaluation/consoleapp1.strings.v9.bin b/20240920/ConsoleApp1/.vs/ProjectEvaluation/consoleapp1.strings.v9.bin new file mode 100644 index 0000000..afbba41 Binary files /dev/null and b/20240920/ConsoleApp1/.vs/ProjectEvaluation/consoleapp1.strings.v9.bin differ diff --git a/20240920/ConsoleApp1/ConsoleApp1.sln b/20240920/ConsoleApp1/ConsoleApp1.sln new file mode 100644 index 0000000..7239cee --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.11.35303.130 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ConsoleApp1", "ConsoleApp1\ConsoleApp1.csproj", "{712B1E33-47B9-442C-B7A2-A5DD3FCFA1DB}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {712B1E33-47B9-442C-B7A2-A5DD3FCFA1DB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {712B1E33-47B9-442C-B7A2-A5DD3FCFA1DB}.Debug|Any CPU.Build.0 = Debug|Any CPU + {712B1E33-47B9-442C-B7A2-A5DD3FCFA1DB}.Release|Any CPU.ActiveCfg = Release|Any CPU + {712B1E33-47B9-442C-B7A2-A5DD3FCFA1DB}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {30A6F478-6ED6-4558-A314-7E1BB7A9E881} + EndGlobalSection +EndGlobal diff --git a/20240920/ConsoleApp1/ConsoleApp1/ConsoleApp1.csproj b/20240920/ConsoleApp1/ConsoleApp1/ConsoleApp1.csproj new file mode 100644 index 0000000..2150e37 --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/ConsoleApp1.csproj @@ -0,0 +1,10 @@ + + + + Exe + net8.0 + enable + enable + + + diff --git a/20240920/ConsoleApp1/ConsoleApp1/Program.cs b/20240920/ConsoleApp1/ConsoleApp1/Program.cs new file mode 100644 index 0000000..a80433d --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/Program.cs @@ -0,0 +1,74 @@ +using System.IO; + +Main(); + +static void Main() +{ + DataRead(); + Console.WriteLine($"Ötven pontnál többet elérők száma: {OtvenFelettiek(Data.tanulok)}"); + Console.WriteLine($"A pontok átlaga: {Atlag(Data.tanulok):F2}"); + List legjobbak = LegjobbHarom(Data.tanulok); + for (int i = 0; i < 3; i++) + { + Console.WriteLine($"{legjobbak[i].Nev}, {legjobbak[i].Pont}"); + } +} + +static int OtvenFelettiek(List list) +{ + var result = list.Where(x => x.Pont > 50).Count(); + return result; +} + +static double Atlag(List list) +{ + var result = list.Average(x => x.Pont); + return result; +} + +static List LegjobbHarom(List list) +{ + //List legjobbharom = list.OrderByDescending(list => list.Pont).ToList(); + List legjobbharom = (from tanulo in list + orderby tanulo.Pont descending + select tanulo).ToList(); + return legjobbharom; +} + +static void DataRead() +{ + string path = "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\tanulok.txt"; + using (StreamReader streamReader = new StreamReader(path)) + { + string line = streamReader.ReadLine(); + line = streamReader.ReadLine(); + + while (line != null) + { + string[] datas = line.Split(','); + Tanulo tanulo = new Tanulo(datas[0], Convert.ToInt32(datas[1])); + Data.tanulok.Add(tanulo); + line = streamReader.ReadLine(); + } + + } +} + + + +public class Tanulo +{ + public string Nev; + public int Pont; + + public Tanulo(string nev, int pont) + { + Nev = nev; + Pont = pont; + } +} + +public static class Data +{ + public static List tanulok = new List(); +} \ No newline at end of file diff --git a/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.deps.json b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.deps.json new file mode 100644 index 0000000..8c6a00b --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.deps.json @@ -0,0 +1,23 @@ +{ + "runtimeTarget": { + "name": ".NETCoreApp,Version=v8.0", + "signature": "" + }, + "compilationOptions": {}, + "targets": { + ".NETCoreApp,Version=v8.0": { + "ConsoleApp1/1.0.0": { + "runtime": { + "ConsoleApp1.dll": {} + } + } + } + }, + "libraries": { + "ConsoleApp1/1.0.0": { + "type": "project", + "serviceable": false, + "sha512": "" + } + } +} \ No newline at end of file diff --git a/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.dll b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.dll new file mode 100644 index 0000000..62f9207 Binary files /dev/null and b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.dll differ diff --git a/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.exe b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.exe new file mode 100644 index 0000000..a614618 Binary files /dev/null and b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.exe differ diff --git a/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.pdb b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.pdb new file mode 100644 index 0000000..d3c51b2 Binary files /dev/null and b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.pdb differ diff --git a/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.runtimeconfig.json b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.runtimeconfig.json new file mode 100644 index 0000000..becfaea --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/bin/Debug/net8.0/ConsoleApp1.runtimeconfig.json @@ -0,0 +1,12 @@ +{ + "runtimeOptions": { + "tfm": "net8.0", + "framework": { + "name": "Microsoft.NETCore.App", + "version": "8.0.0" + }, + "configProperties": { + "System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false + } + } +} \ No newline at end of file diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/ConsoleApp1.csproj.nuget.dgspec.json b/20240920/ConsoleApp1/ConsoleApp1/obj/ConsoleApp1.csproj.nuget.dgspec.json new file mode 100644 index 0000000..a449d86 --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/ConsoleApp1.csproj.nuget.dgspec.json @@ -0,0 +1,68 @@ +{ + "format": 1, + "restore": { + "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\ConsoleApp1.csproj": {} + }, + "projects": { + "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\ConsoleApp1.csproj": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\ConsoleApp1.csproj", + "projectName": "ConsoleApp1", + "projectPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\ConsoleApp1.csproj", + "packagesPath": "C:\\Users\\szabomarton\\.nuget\\packages\\", + "outputPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\szabomarton\\AppData\\Roaming\\NuGet\\NuGet.Config", + "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config" + ], + "originalTargetFrameworks": [ + "net8.0" + ], + "sources": { + "C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {}, + "https://api.nuget.org/v3/index.json": {} + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + }, + "restoreAuditProperties": { + "enableAudit": "true", + "auditLevel": "low", + "auditMode": "direct" + } + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "frameworkReferences": { + "Microsoft.NETCore.App": { + "privateAssets": "all" + } + }, + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\8.0.400/PortableRuntimeIdentifierGraph.json" + } + } + } + } +} \ No newline at end of file diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/ConsoleApp1.csproj.nuget.g.props b/20240920/ConsoleApp1/ConsoleApp1/obj/ConsoleApp1.csproj.nuget.g.props new file mode 100644 index 0000000..8d6358c --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/ConsoleApp1.csproj.nuget.g.props @@ -0,0 +1,15 @@ + + + + True + NuGet + $(MSBuildThisFileDirectory)project.assets.json + $(UserProfile)\.nuget\packages\ + C:\Users\szabomarton\.nuget\packages\ + PackageReference + 6.11.0 + + + + + \ No newline at end of file diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/ConsoleApp1.csproj.nuget.g.targets b/20240920/ConsoleApp1/ConsoleApp1/obj/ConsoleApp1.csproj.nuget.g.targets new file mode 100644 index 0000000..3dc06ef --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/ConsoleApp1.csproj.nuget.g.targets @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs new file mode 100644 index 0000000..2217181 --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs @@ -0,0 +1,4 @@ +// +using System; +using System.Reflection; +[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v8.0", FrameworkDisplayName = ".NET 8.0")] diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.AssemblyInfo.cs b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.AssemblyInfo.cs new file mode 100644 index 0000000..02414c4 --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.AssemblyInfo.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +using System; +using System.Reflection; + +[assembly: System.Reflection.AssemblyCompanyAttribute("ConsoleApp1")] +[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] +[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+82fc6b674fd1265407cef9381f915f8fb7df93c7")] +[assembly: System.Reflection.AssemblyProductAttribute("ConsoleApp1")] +[assembly: System.Reflection.AssemblyTitleAttribute("ConsoleApp1")] +[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] + +// Generated by the MSBuild WriteCodeFragment class. + diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.AssemblyInfoInputs.cache b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.AssemblyInfoInputs.cache new file mode 100644 index 0000000..2679537 --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.AssemblyInfoInputs.cache @@ -0,0 +1 @@ +aa67c41760e97d205100aee5a50d70bd24baabce8f916061a9734dff6619552c diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.GeneratedMSBuildEditorConfig.editorconfig b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.GeneratedMSBuildEditorConfig.editorconfig new file mode 100644 index 0000000..d46964d --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.GeneratedMSBuildEditorConfig.editorconfig @@ -0,0 +1,13 @@ +is_global = true +build_property.TargetFramework = net8.0 +build_property.TargetPlatformMinVersion = +build_property.UsingMicrosoftNETSdkWeb = +build_property.ProjectTypeGuids = +build_property.InvariantGlobalization = +build_property.PlatformNeutralAssembly = +build_property.EnforceExtendedAnalyzerRules = +build_property._SupportedPlatformList = Linux,macOS,Windows +build_property.RootNamespace = ConsoleApp1 +build_property.ProjectDir = C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\ +build_property.EnableComHosting = +build_property.EnableGeneratedComInterfaceComImportInterop = diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.GlobalUsings.g.cs b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.GlobalUsings.g.cs new file mode 100644 index 0000000..8578f3d --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.GlobalUsings.g.cs @@ -0,0 +1,8 @@ +// +global using global::System; +global using global::System.Collections.Generic; +global using global::System.IO; +global using global::System.Linq; +global using global::System.Net.Http; +global using global::System.Threading; +global using global::System.Threading.Tasks; diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.assets.cache b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.assets.cache new file mode 100644 index 0000000..d34f085 Binary files /dev/null and b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.assets.cache differ diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.csproj.BuildWithSkipAnalyzers b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.csproj.BuildWithSkipAnalyzers new file mode 100644 index 0000000..e69de29 diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.csproj.CoreCompileInputs.cache b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.csproj.CoreCompileInputs.cache new file mode 100644 index 0000000..591875d --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.csproj.CoreCompileInputs.cache @@ -0,0 +1 @@ +7f1c35188bf0c59fbea1d24b1d43dc1963ee3d5043bdfb42e9b9890b98c38178 diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.csproj.FileListAbsolute.txt b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.csproj.FileListAbsolute.txt new file mode 100644 index 0000000..107fb99 --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.csproj.FileListAbsolute.txt @@ -0,0 +1,14 @@ +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\obj\Debug\net8.0\ConsoleApp1.GeneratedMSBuildEditorConfig.editorconfig +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\obj\Debug\net8.0\ConsoleApp1.AssemblyInfoInputs.cache +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\obj\Debug\net8.0\ConsoleApp1.AssemblyInfo.cs +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\obj\Debug\net8.0\ConsoleApp1.csproj.CoreCompileInputs.cache +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\bin\Debug\net8.0\ConsoleApp1.exe +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\bin\Debug\net8.0\ConsoleApp1.deps.json +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\bin\Debug\net8.0\ConsoleApp1.runtimeconfig.json +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\bin\Debug\net8.0\ConsoleApp1.dll +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\bin\Debug\net8.0\ConsoleApp1.pdb +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\obj\Debug\net8.0\ConsoleApp1.dll +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\obj\Debug\net8.0\refint\ConsoleApp1.dll +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\obj\Debug\net8.0\ConsoleApp1.pdb +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\obj\Debug\net8.0\ConsoleApp1.genruntimeconfig.cache +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp1\ConsoleApp1\obj\Debug\net8.0\ref\ConsoleApp1.dll diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.dll b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.dll new file mode 100644 index 0000000..62f9207 Binary files /dev/null and b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.dll differ diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.genruntimeconfig.cache b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.genruntimeconfig.cache new file mode 100644 index 0000000..36b95ba --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.genruntimeconfig.cache @@ -0,0 +1 @@ +9b6d263268ab2281cec2217d9f91c5311410da59c6ca98faa5bac969266aab9e diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.pdb b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.pdb new file mode 100644 index 0000000..d3c51b2 Binary files /dev/null and b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ConsoleApp1.pdb differ diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/apphost.exe b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/apphost.exe new file mode 100644 index 0000000..a614618 Binary files /dev/null and b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/apphost.exe differ diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ref/ConsoleApp1.dll b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ref/ConsoleApp1.dll new file mode 100644 index 0000000..b62715d Binary files /dev/null and b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/ref/ConsoleApp1.dll differ diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/refint/ConsoleApp1.dll b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/refint/ConsoleApp1.dll new file mode 100644 index 0000000..b62715d Binary files /dev/null and b/20240920/ConsoleApp1/ConsoleApp1/obj/Debug/net8.0/refint/ConsoleApp1.dll differ diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/project.assets.json b/20240920/ConsoleApp1/ConsoleApp1/obj/project.assets.json new file mode 100644 index 0000000..5f97f0f --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/project.assets.json @@ -0,0 +1,73 @@ +{ + "version": 3, + "targets": { + "net8.0": {} + }, + "libraries": {}, + "projectFileDependencyGroups": { + "net8.0": [] + }, + "packageFolders": { + "C:\\Users\\szabomarton\\.nuget\\packages\\": {} + }, + "project": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\ConsoleApp1.csproj", + "projectName": "ConsoleApp1", + "projectPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\ConsoleApp1.csproj", + "packagesPath": "C:\\Users\\szabomarton\\.nuget\\packages\\", + "outputPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\szabomarton\\AppData\\Roaming\\NuGet\\NuGet.Config", + "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config" + ], + "originalTargetFrameworks": [ + "net8.0" + ], + "sources": { + "C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {}, + "https://api.nuget.org/v3/index.json": {} + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + }, + "restoreAuditProperties": { + "enableAudit": "true", + "auditLevel": "low", + "auditMode": "direct" + } + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "frameworkReferences": { + "Microsoft.NETCore.App": { + "privateAssets": "all" + } + }, + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\8.0.400/PortableRuntimeIdentifierGraph.json" + } + } + } +} \ No newline at end of file diff --git a/20240920/ConsoleApp1/ConsoleApp1/obj/project.nuget.cache b/20240920/ConsoleApp1/ConsoleApp1/obj/project.nuget.cache new file mode 100644 index 0000000..0d37596 --- /dev/null +++ b/20240920/ConsoleApp1/ConsoleApp1/obj/project.nuget.cache @@ -0,0 +1,8 @@ +{ + "version": 2, + "dgSpecHash": "N3V9pefyNFs=", + "success": true, + "projectFilePath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp1\\ConsoleApp1\\ConsoleApp1.csproj", + "expectedPackageFiles": [], + "logs": [] +} \ No newline at end of file diff --git a/20240920/ConsoleApp2/.vs/ConsoleApp2/DesignTimeBuild/.dtbcache.v2 b/20240920/ConsoleApp2/.vs/ConsoleApp2/DesignTimeBuild/.dtbcache.v2 new file mode 100644 index 0000000..b9a4db7 Binary files /dev/null and b/20240920/ConsoleApp2/.vs/ConsoleApp2/DesignTimeBuild/.dtbcache.v2 differ diff --git a/20240920/ConsoleApp2/.vs/ConsoleApp2/FileContentIndex/208e9ca9-1a6a-4135-ae07-4903f8663eee.vsidx b/20240920/ConsoleApp2/.vs/ConsoleApp2/FileContentIndex/208e9ca9-1a6a-4135-ae07-4903f8663eee.vsidx new file mode 100644 index 0000000..6a5390b Binary files /dev/null and b/20240920/ConsoleApp2/.vs/ConsoleApp2/FileContentIndex/208e9ca9-1a6a-4135-ae07-4903f8663eee.vsidx differ diff --git a/20240920/ConsoleApp2/.vs/ConsoleApp2/FileContentIndex/8e6bf2d2-b276-408f-a2cf-cd27e3a09016.vsidx b/20240920/ConsoleApp2/.vs/ConsoleApp2/FileContentIndex/8e6bf2d2-b276-408f-a2cf-cd27e3a09016.vsidx new file mode 100644 index 0000000..1ba9cc2 Binary files /dev/null and b/20240920/ConsoleApp2/.vs/ConsoleApp2/FileContentIndex/8e6bf2d2-b276-408f-a2cf-cd27e3a09016.vsidx differ diff --git a/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/.futdcache.v2 b/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/.futdcache.v2 new file mode 100644 index 0000000..b65986d Binary files /dev/null and b/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/.futdcache.v2 differ diff --git a/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/.suo b/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/.suo new file mode 100644 index 0000000..3adef0a Binary files /dev/null and b/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/.suo differ diff --git a/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/DocumentLayout.backup.json b/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/DocumentLayout.backup.json new file mode 100644 index 0000000..4326552 --- /dev/null +++ b/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/DocumentLayout.backup.json @@ -0,0 +1,41 @@ +{ + "Version": 1, + "WorkspaceRootPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\", + "Documents": [ + { + "AbsoluteMoniker": "D:0:0:{07865C0D-EE88-4AE8-8F14-75DE240A66E7}|ConsoleApp2\\ConsoleApp2.csproj|c:\\users\\szabomarton\\desktop\\c#\\progaora\\20240920\\consoleapp2\\consoleapp2\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", + "RelativeMoniker": "D:0:0:{07865C0D-EE88-4AE8-8F14-75DE240A66E7}|ConsoleApp2\\ConsoleApp2.csproj|solutionrelative:consoleapp2\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}" + } + ], + "DocumentGroupContainers": [ + { + "Orientation": 0, + "VerticalTabListWidth": 256, + "DocumentGroups": [ + { + "DockedWidth": 200, + "SelectedChildIndex": 0, + "Children": [ + { + "$type": "Document", + "DocumentIndex": 0, + "Title": "Program.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\Program.cs", + "RelativeDocumentMoniker": "ConsoleApp2\\Program.cs", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\Program.cs", + "RelativeToolTip": "ConsoleApp2\\Program.cs", + "ViewState": "AgIAAAAAAAAAAAAAAAAAAAQAAABCAAAAAAAAAA==", + "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", + "WhenOpened": "2024-09-20T09:02:47.555Z", + "EditorCaption": "" + }, + { + "$type": "Bookmark", + "Name": "ST:0:0:{cce594b6-0c39-4442-ba28-10c64ac7e89f}" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/DocumentLayout.json b/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/DocumentLayout.json new file mode 100644 index 0000000..d91e38e --- /dev/null +++ b/20240920/ConsoleApp2/.vs/ConsoleApp2/v17/DocumentLayout.json @@ -0,0 +1,41 @@ +{ + "Version": 1, + "WorkspaceRootPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\", + "Documents": [ + { + "AbsoluteMoniker": "D:0:0:{07865C0D-EE88-4AE8-8F14-75DE240A66E7}|ConsoleApp2\\ConsoleApp2.csproj|c:\\users\\szabomarton\\desktop\\c#\\progaora\\20240920\\consoleapp2\\consoleapp2\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}", + "RelativeMoniker": "D:0:0:{07865C0D-EE88-4AE8-8F14-75DE240A66E7}|ConsoleApp2\\ConsoleApp2.csproj|solutionrelative:consoleapp2\\program.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}" + } + ], + "DocumentGroupContainers": [ + { + "Orientation": 0, + "VerticalTabListWidth": 256, + "DocumentGroups": [ + { + "DockedWidth": 200, + "SelectedChildIndex": 0, + "Children": [ + { + "$type": "Document", + "DocumentIndex": 0, + "Title": "Program.cs", + "DocumentMoniker": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\Program.cs", + "RelativeDocumentMoniker": "ConsoleApp2\\Program.cs", + "ToolTip": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\Program.cs", + "RelativeToolTip": "ConsoleApp2\\Program.cs", + "ViewState": "AgIAAAAAAAAAAAAAAAAAAAcAAAAlAAAAAAAAAA==", + "Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|", + "WhenOpened": "2024-09-20T09:02:47.555Z", + "EditorCaption": "" + }, + { + "$type": "Bookmark", + "Name": "ST:0:0:{cce594b6-0c39-4442-ba28-10c64ac7e89f}" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/20240920/ConsoleApp2/ConsoleApp2.sln b/20240920/ConsoleApp2/ConsoleApp2.sln new file mode 100644 index 0000000..01ff1e8 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.11.35303.130 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ConsoleApp2", "ConsoleApp2\ConsoleApp2.csproj", "{07865C0D-EE88-4AE8-8F14-75DE240A66E7}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {07865C0D-EE88-4AE8-8F14-75DE240A66E7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {07865C0D-EE88-4AE8-8F14-75DE240A66E7}.Debug|Any CPU.Build.0 = Debug|Any CPU + {07865C0D-EE88-4AE8-8F14-75DE240A66E7}.Release|Any CPU.ActiveCfg = Release|Any CPU + {07865C0D-EE88-4AE8-8F14-75DE240A66E7}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {C623C855-ECC2-437F-8EBD-DA3838B10898} + EndGlobalSection +EndGlobal diff --git a/20240920/ConsoleApp2/ConsoleApp2/ConsoleApp2.csproj b/20240920/ConsoleApp2/ConsoleApp2/ConsoleApp2.csproj new file mode 100644 index 0000000..2150e37 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/ConsoleApp2.csproj @@ -0,0 +1,10 @@ + + + + Exe + net8.0 + enable + enable + + + diff --git a/20240920/ConsoleApp2/ConsoleApp2/Program.cs b/20240920/ConsoleApp2/ConsoleApp2/Program.cs new file mode 100644 index 0000000..ad30210 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/Program.cs @@ -0,0 +1,63 @@ +DataRead(); +Varos legmelegebb = Legmelegebb(); +Console.WriteLine($"{legmelegebb.Nev} {legmelegebb.Homerseklet}"); +Varos leghidegebb = Leghidegebb(); +Console.WriteLine($"{leghidegebb.Nev} {leghidegebb.Homerseklet}"); +double atlag = Atlag(); +Console.WriteLine($"Átlag hőmérséklet: {atlag:F2}"); +//list városok where homerseklet > 20 + +static double Atlag() +{ + return Data.varosok.Average(x => x.Homerseklet); +} + +static Varos Leghidegebb() +{ + var legmelegebb = Data.varosok.OrderBy(x => x.Homerseklet).Take(1); + return legmelegebb.First(); +} + +static Varos Legmelegebb() +{ + var legmelegebb = Data.varosok.OrderByDescending(x => x.Homerseklet).Take(1); + return legmelegebb.First(); +} + +static void DataRead() +{ + string path = "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\varosok.txt"; + using (StreamReader streamReader = new StreamReader(path)) + { + string line = streamReader.ReadLine(); + line = streamReader.ReadLine(); + + while (line != null) + { + string[] datas = line.Split(','); + Varos varos = new Varos(datas[0], Convert.ToInt32(datas[1])); + Data.varosok.Add(varos); + line = streamReader.ReadLine(); + } + + } +} + + + +public class Varos +{ + public string Nev; + public int Homerseklet; + + public Varos(string nev, int homerseklet) + { + Nev = nev; + Homerseklet = homerseklet; + } +} + +public static class Data +{ + public static List varosok = new List(); +} \ No newline at end of file diff --git a/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.deps.json b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.deps.json new file mode 100644 index 0000000..9d949d9 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.deps.json @@ -0,0 +1,23 @@ +{ + "runtimeTarget": { + "name": ".NETCoreApp,Version=v8.0", + "signature": "" + }, + "compilationOptions": {}, + "targets": { + ".NETCoreApp,Version=v8.0": { + "ConsoleApp2/1.0.0": { + "runtime": { + "ConsoleApp2.dll": {} + } + } + } + }, + "libraries": { + "ConsoleApp2/1.0.0": { + "type": "project", + "serviceable": false, + "sha512": "" + } + } +} \ No newline at end of file diff --git a/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.dll b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.dll new file mode 100644 index 0000000..5fc009e Binary files /dev/null and b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.dll differ diff --git a/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.exe b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.exe new file mode 100644 index 0000000..41c6a04 Binary files /dev/null and b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.exe differ diff --git a/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.pdb b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.pdb new file mode 100644 index 0000000..18b80b1 Binary files /dev/null and b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.pdb differ diff --git a/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.runtimeconfig.json b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.runtimeconfig.json new file mode 100644 index 0000000..becfaea --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/bin/Debug/net8.0/ConsoleApp2.runtimeconfig.json @@ -0,0 +1,12 @@ +{ + "runtimeOptions": { + "tfm": "net8.0", + "framework": { + "name": "Microsoft.NETCore.App", + "version": "8.0.0" + }, + "configProperties": { + "System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false + } + } +} \ No newline at end of file diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/ConsoleApp2.csproj.nuget.dgspec.json b/20240920/ConsoleApp2/ConsoleApp2/obj/ConsoleApp2.csproj.nuget.dgspec.json new file mode 100644 index 0000000..ac02378 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/ConsoleApp2.csproj.nuget.dgspec.json @@ -0,0 +1,68 @@ +{ + "format": 1, + "restore": { + "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\ConsoleApp2.csproj": {} + }, + "projects": { + "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\ConsoleApp2.csproj": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\ConsoleApp2.csproj", + "projectName": "ConsoleApp2", + "projectPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\ConsoleApp2.csproj", + "packagesPath": "C:\\Users\\szabomarton\\.nuget\\packages\\", + "outputPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\szabomarton\\AppData\\Roaming\\NuGet\\NuGet.Config", + "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config" + ], + "originalTargetFrameworks": [ + "net8.0" + ], + "sources": { + "C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {}, + "https://api.nuget.org/v3/index.json": {} + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + }, + "restoreAuditProperties": { + "enableAudit": "true", + "auditLevel": "low", + "auditMode": "direct" + } + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "frameworkReferences": { + "Microsoft.NETCore.App": { + "privateAssets": "all" + } + }, + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\8.0.400/PortableRuntimeIdentifierGraph.json" + } + } + } + } +} \ No newline at end of file diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/ConsoleApp2.csproj.nuget.g.props b/20240920/ConsoleApp2/ConsoleApp2/obj/ConsoleApp2.csproj.nuget.g.props new file mode 100644 index 0000000..8d6358c --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/ConsoleApp2.csproj.nuget.g.props @@ -0,0 +1,15 @@ + + + + True + NuGet + $(MSBuildThisFileDirectory)project.assets.json + $(UserProfile)\.nuget\packages\ + C:\Users\szabomarton\.nuget\packages\ + PackageReference + 6.11.0 + + + + + \ No newline at end of file diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/ConsoleApp2.csproj.nuget.g.targets b/20240920/ConsoleApp2/ConsoleApp2/obj/ConsoleApp2.csproj.nuget.g.targets new file mode 100644 index 0000000..3dc06ef --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/ConsoleApp2.csproj.nuget.g.targets @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs new file mode 100644 index 0000000..2217181 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs @@ -0,0 +1,4 @@ +// +using System; +using System.Reflection; +[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v8.0", FrameworkDisplayName = ".NET 8.0")] diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.AssemblyInfo.cs b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.AssemblyInfo.cs new file mode 100644 index 0000000..4795534 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.AssemblyInfo.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +using System; +using System.Reflection; + +[assembly: System.Reflection.AssemblyCompanyAttribute("ConsoleApp2")] +[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] +[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+82fc6b674fd1265407cef9381f915f8fb7df93c7")] +[assembly: System.Reflection.AssemblyProductAttribute("ConsoleApp2")] +[assembly: System.Reflection.AssemblyTitleAttribute("ConsoleApp2")] +[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] + +// Generated by the MSBuild WriteCodeFragment class. + diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.AssemblyInfoInputs.cache b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.AssemblyInfoInputs.cache new file mode 100644 index 0000000..2c996ef --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.AssemblyInfoInputs.cache @@ -0,0 +1 @@ +689549fe51d153fc5f381a183ba624cac369dd48a7be85a2b1c61abb3a853dc8 diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.GeneratedMSBuildEditorConfig.editorconfig b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.GeneratedMSBuildEditorConfig.editorconfig new file mode 100644 index 0000000..7503a16 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.GeneratedMSBuildEditorConfig.editorconfig @@ -0,0 +1,13 @@ +is_global = true +build_property.TargetFramework = net8.0 +build_property.TargetPlatformMinVersion = +build_property.UsingMicrosoftNETSdkWeb = +build_property.ProjectTypeGuids = +build_property.InvariantGlobalization = +build_property.PlatformNeutralAssembly = +build_property.EnforceExtendedAnalyzerRules = +build_property._SupportedPlatformList = Linux,macOS,Windows +build_property.RootNamespace = ConsoleApp2 +build_property.ProjectDir = C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\ +build_property.EnableComHosting = +build_property.EnableGeneratedComInterfaceComImportInterop = diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.GlobalUsings.g.cs b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.GlobalUsings.g.cs new file mode 100644 index 0000000..8578f3d --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.GlobalUsings.g.cs @@ -0,0 +1,8 @@ +// +global using global::System; +global using global::System.Collections.Generic; +global using global::System.IO; +global using global::System.Linq; +global using global::System.Net.Http; +global using global::System.Threading; +global using global::System.Threading.Tasks; diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.assets.cache b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.assets.cache new file mode 100644 index 0000000..991611c Binary files /dev/null and b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.assets.cache differ diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.csproj.BuildWithSkipAnalyzers b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.csproj.BuildWithSkipAnalyzers new file mode 100644 index 0000000..e69de29 diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.csproj.CoreCompileInputs.cache b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.csproj.CoreCompileInputs.cache new file mode 100644 index 0000000..5ae16be --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.csproj.CoreCompileInputs.cache @@ -0,0 +1 @@ +18ad58a4a862825168fc500f7f1e04509977c1e3da94c2a4ab1f91d365d5f40b diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.csproj.FileListAbsolute.txt b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.csproj.FileListAbsolute.txt new file mode 100644 index 0000000..1c91235 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.csproj.FileListAbsolute.txt @@ -0,0 +1,14 @@ +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\obj\Debug\net8.0\ConsoleApp2.GeneratedMSBuildEditorConfig.editorconfig +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\obj\Debug\net8.0\ConsoleApp2.AssemblyInfoInputs.cache +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\obj\Debug\net8.0\ConsoleApp2.AssemblyInfo.cs +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\obj\Debug\net8.0\ConsoleApp2.csproj.CoreCompileInputs.cache +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\bin\Debug\net8.0\ConsoleApp2.exe +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\bin\Debug\net8.0\ConsoleApp2.deps.json +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\bin\Debug\net8.0\ConsoleApp2.runtimeconfig.json +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\bin\Debug\net8.0\ConsoleApp2.dll +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\bin\Debug\net8.0\ConsoleApp2.pdb +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\obj\Debug\net8.0\ConsoleApp2.dll +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\obj\Debug\net8.0\refint\ConsoleApp2.dll +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\obj\Debug\net8.0\ConsoleApp2.pdb +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\obj\Debug\net8.0\ConsoleApp2.genruntimeconfig.cache +C:\Users\szabomarton\Desktop\C#\ProgaOra\20240920\ConsoleApp2\ConsoleApp2\obj\Debug\net8.0\ref\ConsoleApp2.dll diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.dll b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.dll new file mode 100644 index 0000000..5fc009e Binary files /dev/null and b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.dll differ diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.genruntimeconfig.cache b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.genruntimeconfig.cache new file mode 100644 index 0000000..a495da6 --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.genruntimeconfig.cache @@ -0,0 +1 @@ +2629f07ba15577b1c9eed9ff991ca0c682fb80978d3abeb885542c641f6e96ba diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.pdb b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.pdb new file mode 100644 index 0000000..18b80b1 Binary files /dev/null and b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ConsoleApp2.pdb differ diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/apphost.exe b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/apphost.exe new file mode 100644 index 0000000..41c6a04 Binary files /dev/null and b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/apphost.exe differ diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ref/ConsoleApp2.dll b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ref/ConsoleApp2.dll new file mode 100644 index 0000000..c00a817 Binary files /dev/null and b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/ref/ConsoleApp2.dll differ diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/refint/ConsoleApp2.dll b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/refint/ConsoleApp2.dll new file mode 100644 index 0000000..c00a817 Binary files /dev/null and b/20240920/ConsoleApp2/ConsoleApp2/obj/Debug/net8.0/refint/ConsoleApp2.dll differ diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/project.assets.json b/20240920/ConsoleApp2/ConsoleApp2/obj/project.assets.json new file mode 100644 index 0000000..231a53a --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/project.assets.json @@ -0,0 +1,73 @@ +{ + "version": 3, + "targets": { + "net8.0": {} + }, + "libraries": {}, + "projectFileDependencyGroups": { + "net8.0": [] + }, + "packageFolders": { + "C:\\Users\\szabomarton\\.nuget\\packages\\": {} + }, + "project": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\ConsoleApp2.csproj", + "projectName": "ConsoleApp2", + "projectPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\ConsoleApp2.csproj", + "packagesPath": "C:\\Users\\szabomarton\\.nuget\\packages\\", + "outputPath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\szabomarton\\AppData\\Roaming\\NuGet\\NuGet.Config", + "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config" + ], + "originalTargetFrameworks": [ + "net8.0" + ], + "sources": { + "C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {}, + "https://api.nuget.org/v3/index.json": {} + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + }, + "restoreAuditProperties": { + "enableAudit": "true", + "auditLevel": "low", + "auditMode": "direct" + } + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "frameworkReferences": { + "Microsoft.NETCore.App": { + "privateAssets": "all" + } + }, + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\8.0.400/PortableRuntimeIdentifierGraph.json" + } + } + } +} \ No newline at end of file diff --git a/20240920/ConsoleApp2/ConsoleApp2/obj/project.nuget.cache b/20240920/ConsoleApp2/ConsoleApp2/obj/project.nuget.cache new file mode 100644 index 0000000..482501e --- /dev/null +++ b/20240920/ConsoleApp2/ConsoleApp2/obj/project.nuget.cache @@ -0,0 +1,8 @@ +{ + "version": 2, + "dgSpecHash": "0sx9Yfcwk0I=", + "success": true, + "projectFilePath": "C:\\Users\\szabomarton\\Desktop\\C#\\ProgaOra\\20240920\\ConsoleApp2\\ConsoleApp2\\ConsoleApp2.csproj", + "expectedPackageFiles": [], + "logs": [] +} \ No newline at end of file diff --git a/20240920/tanulok.txt b/20240920/tanulok.txt new file mode 100644 index 0000000..7b048fa --- /dev/null +++ b/20240920/tanulok.txt @@ -0,0 +1,18 @@ +Név,Eredmény +Kovács Péter,85 +Szabó Réka,45 +Nagy Ádám,92 +Varga Anna,76 +Tóth Levente,54 +Kiss Gergely,88 +Farkas Boglárka,62 +Molnár Dávid,71 +Horváth Csenge,89 +Fehér Balázs,58 +Kovács László,75 +Varga Tamás,63 +Boros Ákos,91 +Veres Kitti,87 +Szabó Máté,59 +Nagy Vivien,92 +Tóth Emese,73 diff --git a/20240920/varosok.txt b/20240920/varosok.txt new file mode 100644 index 0000000..93357bb --- /dev/null +++ b/20240920/varosok.txt @@ -0,0 +1,18 @@ +Város,Hőmérséklet +Budapest,22 +Debrecen,19 +Szeged,24 +Pécs,21 +Győr,18 +Székesfehérvár,20 +Miskolc,17 +Nyíregyháza,16 +Kecskemét,23 +Zalaegerszeg,18 +Tatabánya,20 +Sopron,19 +Szombathely,22 +Békéscsaba,21 +Érd,20 +Siófok,25 +Kaposvár,17 diff --git a/form_anyag b/form_anyag index 0128ebf..d326c6d 100644 --- a/form_anyag +++ b/form_anyag @@ -326,3 +326,26 @@ Azt hogy a lenyíló lista milyen stílusú legyen, a DropDownStyle tulajdonság Feladat: beolvasás szövegfájlból kiírás fájlba. Szamok.txt tartalmát válogassa párosra és páratlanra. + + +-------------------------------------------------------------- + +Fájlkezelés using - gal + + + +A using kulcsszó a c# ban egy speciális konstrukció, amely biztosítja, hogy egy adott erőforrás, mint pl fájl vagy hálózati kapcsolat, automatikusan felszabaduljon, miután már nincs rá szükség. + +A using blokkot tipikusan olyan erőforrások kezellslre használjuk, amelyek implementálják az IDisposible inteface-t, és ameéyeket manuálisan kellene felszabadítani (pl fájlok, adatbázis-kapcsolatok, hálózati erőforrások stb). +A using automatiikusan gondoskodik arról, hogy az erőforrás helyesen lezáródjon vagy felszabaduljon, amikor a kód végrehajtása elhagyja a using blokkot, még akkor is, ha kivétel történik. +A usingot arra használjuk, hogy biztosítsuk az erőforrások, például fájlok, adatbázis-kapcsolatok, és hálózati erőforrások autómatikus és biztonságos felszabadítását, amikor azok már nem szükségesek. + +Használatának előnyei: + Automatikus felszabadítás + nem kell .Dispose() + Könnyebb kód + a kód egyszerűbbé válik, mert automatikusan kezeli az erőforrások felszabadítását + Hibakezelés + ha egy kivétel lép fel a using blokkban az erőforrás akkor is megfelelően lezáródik. + + diff --git a/linq_anyag b/linq_anyag index 38798bf..fcef298 100644 --- a/linq_anyag +++ b/linq_anyag @@ -37,3 +37,71 @@ kihagyás Skip() Take() //csak adott számú elem kiválasztása var eredmeny = elemek.Skip(2).Take(3); + + + +Elemek kiválasztása: + First() + Ha nincs elem akkor kivételt dob + FirstOrDefault() + Kivétel esetén a típus alapértelmezett értékét dobja vissza + Last() + LastOrDefault() + + ElementAt(index) + ElementAtOrDefault(index) + +Ismétlődések kiszűrése + Ismétlődés kiszűrésére a Distinct metódus alkalmazható. + Alkalmazásának feltétele, hogy ha a típusunk egy összetett típus, ami több elemet tartalmaz, akkor rendelkezzen egy megfelelően felülírt Equals metódussal. + Alternatívként adhatunk meg egy IEqualityComparer interface metódus-t megvalósító típus példányt. + + var egyedix = elemek.DistinctBy(i => i.x); + +Aggregáló műveletek + Ha kollekció eredményének számosságára vagyunk kíváncsiak, akkor a Count() metódus alkalmazhatjuk. + var parosx = elemek.Count(i => i.X%2 ==0); + +Feltételek esetén, ha azt szeretnénk kiértékelni, hogy egyáltalán van e eredménye a keresésnek, akkor a Cpunt() > 0 kifejezés erősen kerülendő, mert ez végig megy a kollekción és végigszámolja az elemeket. +Helyette az Any() metódust használjuk, ami eleve erre lett kitalálva. +Az Any() igaz értéket ad vissza, ha az IEnumerable típisusnk tartalmaz elemeket. +Paraméterrel is kiegészíthetjük. +Ebben az esetben azt mondja meg, hogy a kollekció tartalmaz-e a feltételnek megfelelő elemet. + +Ha egy kollekció esetén minimum vagy maximum értékre vagyunk kíváncsiak, akkor a Min() és Max() metódusokat alkalmazhatjuk. +Ha a kollekció szám típusokból áll, akkor paraméter nem kell adnunk. +Ellenkező esetben kell egy kifejezés, ami megmondja, hogy mi alapján számolódjon meg a min és max érték. +Átlagosra hasonló működéssel az Avg() metódus alkalmazható. + +var MaxX = elemek.Max( i => i.X); + +var MinY = elemek.Min( i => i.Y); + +vor avg = elemek.Avg( i => i.Y * i.X); + +int[] ints1 = {5,56,535434,435473854,45}; +int[] ints2 = {58,56448,38647,4,45,5,6,56}; + +//unió +IEnumerable union = ints1.Union(ints2); + +//metszet +IEnumerable intersect = ints1.Intersect(ints2); + +// különbség +IEnumerable except = ints1.Except(ints2); + +//Concat +var concatenated = ints1.Concat(ints2); + +Ha olyan módon szeretnénk összefűzni elemeket, hogy 1 elemet szeretnénk venni az első kollekcióóból, majd egy elemet szeretnénk a második kollekcióból. +Erre a zip művelet képes +ami a ValueTuple formában adja vissza az elemeket. + +var result = a.zip(b); + +szeletelés +Chunk műveletet, amivel egy IEnumerable típust fel tudunk szeletelni több, megadott maximum elemszámú T típusú tömbre. +int[] a = {1,2,3,4}; +IEnumerable result = a.chunk(2); +//[1,2] és [3,4] tömböket produkál