diff --git a/.vs/Sakk/v17/.suo b/.vs/Sakk/v17/.suo index fc92bc5..22b0485 100644 Binary files a/.vs/Sakk/v17/.suo and b/.vs/Sakk/v17/.suo differ diff --git a/Sakk.sln b/Sakk.sln index c05a6a6..3073bbf 100644 --- a/Sakk.sln +++ b/Sakk.sln @@ -8,13 +8,19 @@ EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU + Debug|x64 = Debug|x64 Release|Any CPU = Release|Any CPU + Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution {D58A69DD-68B9-4280-8DDD-57B73B4EAC21}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {D58A69DD-68B9-4280-8DDD-57B73B4EAC21}.Debug|Any CPU.Build.0 = Debug|Any CPU + {D58A69DD-68B9-4280-8DDD-57B73B4EAC21}.Debug|x64.ActiveCfg = Debug|x64 + {D58A69DD-68B9-4280-8DDD-57B73B4EAC21}.Debug|x64.Build.0 = Debug|x64 {D58A69DD-68B9-4280-8DDD-57B73B4EAC21}.Release|Any CPU.ActiveCfg = Release|Any CPU {D58A69DD-68B9-4280-8DDD-57B73B4EAC21}.Release|Any CPU.Build.0 = Release|Any CPU + {D58A69DD-68B9-4280-8DDD-57B73B4EAC21}.Release|x64.ActiveCfg = Release|x64 + {D58A69DD-68B9-4280-8DDD-57B73B4EAC21}.Release|x64.Build.0 = Release|x64 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/Sakk/Program.cs b/Sakk/Program.cs index 12e0539..e2dc689 100644 --- a/Sakk/Program.cs +++ b/Sakk/Program.cs @@ -24,16 +24,57 @@ namespace Sakk { return true; //ha nem talalt sehol se babut akkor return true } - static void Main(string[] args) { - int lehetosegek = 0; - + public static void kiir() { for (int i = 0; i < tabla.GetLength(0); i++) { for (int j = 0; j < tabla.GetLength(1); j++) { - + Console.Write(tabla[i,j] + " "); } + Console.WriteLine(); + } + } + + static void Main(string[] args) { + //problema ha el van tolva a sor vagy az oszlop nem rak le 8 babut + //csak egy fajta variaciot tud megcsinalni + Random random = new Random(); + List tablak = new List(); + //int lehetosegek = 0; + int babuk = 0; + int akt_sor = 0; + bool nem_jo_ketszer = false; + int elozo_poz = 0, elozo_sor = 0; + + while(babuk < 9) { + int pozicio = random.Next(0, 7); + Console.WriteLine("pozicio: " + pozicio); + Console.WriteLine("akt sor:" + akt_sor); + if(sorEllenorzes(akt_sor) && oszlopEllenorzes(pozicio)) { + tabla[akt_sor, pozicio] = 1; + elozo_poz = pozicio; //elozo babu elmentese + elozo_sor = akt_sor; + babuk++; + akt_sor++; + } + + if(elozo_sor == akt_sor) { + nem_jo_ketszer = true; + if (nem_jo_ketszer) { + tabla = new int[8, 8]; + babuk = 0, + } + } + + //atnezni van e mar ez a tabla eltarolva + if(babuk == 8) { + tablak.Add(tabla); + } + + kiir(); } + + Console.ReadKey(); } } diff --git a/Sakk/Sakk.csproj b/Sakk/Sakk.csproj index 167c22d..f44b8e2 100644 --- a/Sakk/Sakk.csproj +++ b/Sakk/Sakk.csproj @@ -32,6 +32,26 @@ prompt 4 + + true + bin\x64\Debug\ + DEBUG;TRACE + full + x64 + 7.3 + prompt + true + + + bin\x64\Release\ + TRACE + true + pdbonly + x64 + 7.3 + prompt + true + diff --git a/Sakk/bin/Debug/Sakk.exe b/Sakk/bin/Debug/Sakk.exe index 148ca56..5eeb586 100644 Binary files a/Sakk/bin/Debug/Sakk.exe and b/Sakk/bin/Debug/Sakk.exe differ diff --git a/Sakk/bin/Debug/Sakk.pdb b/Sakk/bin/Debug/Sakk.pdb index c2e6e3d..bfc57f7 100644 Binary files a/Sakk/bin/Debug/Sakk.pdb and b/Sakk/bin/Debug/Sakk.pdb differ diff --git a/Sakk/bin/x64/Debug/Sakk.exe b/Sakk/bin/x64/Debug/Sakk.exe new file mode 100644 index 0000000..975e94d Binary files /dev/null and b/Sakk/bin/x64/Debug/Sakk.exe differ diff --git a/Sakk/bin/x64/Debug/Sakk.exe.config b/Sakk/bin/x64/Debug/Sakk.exe.config new file mode 100644 index 0000000..56efbc7 --- /dev/null +++ b/Sakk/bin/x64/Debug/Sakk.exe.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/Sakk/bin/x64/Debug/Sakk.pdb b/Sakk/bin/x64/Debug/Sakk.pdb new file mode 100644 index 0000000..64fba69 Binary files /dev/null and b/Sakk/bin/x64/Debug/Sakk.pdb differ diff --git a/Sakk/obj/Debug/Sakk.exe b/Sakk/obj/Debug/Sakk.exe index 148ca56..5eeb586 100644 Binary files a/Sakk/obj/Debug/Sakk.exe and b/Sakk/obj/Debug/Sakk.exe differ diff --git a/Sakk/obj/Debug/Sakk.pdb b/Sakk/obj/Debug/Sakk.pdb index c2e6e3d..bfc57f7 100644 Binary files a/Sakk/obj/Debug/Sakk.pdb and b/Sakk/obj/Debug/Sakk.pdb differ diff --git a/Sakk/obj/x64/Debug/.NETFramework,Version=v4.7.2.AssemblyAttributes.cs b/Sakk/obj/x64/Debug/.NETFramework,Version=v4.7.2.AssemblyAttributes.cs new file mode 100644 index 0000000..3871b18 --- /dev/null +++ b/Sakk/obj/x64/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/Sakk/obj/x64/Debug/DesignTimeResolveAssemblyReferencesInput.cache b/Sakk/obj/x64/Debug/DesignTimeResolveAssemblyReferencesInput.cache new file mode 100644 index 0000000..2bf5614 Binary files /dev/null and b/Sakk/obj/x64/Debug/DesignTimeResolveAssemblyReferencesInput.cache differ diff --git a/Sakk/obj/x64/Debug/Sakk.csproj.AssemblyReference.cache b/Sakk/obj/x64/Debug/Sakk.csproj.AssemblyReference.cache new file mode 100644 index 0000000..126ed02 Binary files /dev/null and b/Sakk/obj/x64/Debug/Sakk.csproj.AssemblyReference.cache differ diff --git a/Sakk/obj/x64/Debug/Sakk.csproj.CoreCompileInputs.cache b/Sakk/obj/x64/Debug/Sakk.csproj.CoreCompileInputs.cache new file mode 100644 index 0000000..1abd691 --- /dev/null +++ b/Sakk/obj/x64/Debug/Sakk.csproj.CoreCompileInputs.cache @@ -0,0 +1 @@ +a716bfef2e809d656a083b5be6f3dfe2908c1bec diff --git a/Sakk/obj/x64/Debug/Sakk.csproj.FileListAbsolute.txt b/Sakk/obj/x64/Debug/Sakk.csproj.FileListAbsolute.txt new file mode 100644 index 0000000..ea24319 --- /dev/null +++ b/Sakk/obj/x64/Debug/Sakk.csproj.FileListAbsolute.txt @@ -0,0 +1,8 @@ +C:\dev\c#\Sakk\Sakk\bin\x64\Debug\Sakk.exe.config +C:\dev\c#\Sakk\Sakk\bin\x64\Debug\Sakk.exe +C:\dev\c#\Sakk\Sakk\bin\x64\Debug\Sakk.pdb +C:\dev\c#\Sakk\Sakk\obj\x64\Debug\Sakk.csproj.AssemblyReference.cache +C:\dev\c#\Sakk\Sakk\obj\x64\Debug\Sakk.csproj.SuggestedBindingRedirects.cache +C:\dev\c#\Sakk\Sakk\obj\x64\Debug\Sakk.csproj.CoreCompileInputs.cache +C:\dev\c#\Sakk\Sakk\obj\x64\Debug\Sakk.exe +C:\dev\c#\Sakk\Sakk\obj\x64\Debug\Sakk.pdb diff --git a/Sakk/obj/x64/Debug/Sakk.csproj.SuggestedBindingRedirects.cache b/Sakk/obj/x64/Debug/Sakk.csproj.SuggestedBindingRedirects.cache new file mode 100644 index 0000000..e69de29 diff --git a/Sakk/obj/x64/Debug/Sakk.exe b/Sakk/obj/x64/Debug/Sakk.exe new file mode 100644 index 0000000..975e94d Binary files /dev/null and b/Sakk/obj/x64/Debug/Sakk.exe differ diff --git a/Sakk/obj/x64/Debug/Sakk.pdb b/Sakk/obj/x64/Debug/Sakk.pdb new file mode 100644 index 0000000..64fba69 Binary files /dev/null and b/Sakk/obj/x64/Debug/Sakk.pdb differ