update3
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
6
Fibonacci/App.config
Normal file
6
Fibonacci/App.config
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
|
<configuration>
|
||||||
|
<startup>
|
||||||
|
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||||
|
</startup>
|
||||||
|
</configuration>
|
||||||
53
Fibonacci/Fibonacci.csproj
Normal file
53
Fibonacci/Fibonacci.csproj
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||||
|
<PropertyGroup>
|
||||||
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
|
<ProjectGuid>{FAE7220C-8E06-4D42-B54C-573A60584C51}</ProjectGuid>
|
||||||
|
<OutputType>Exe</OutputType>
|
||||||
|
<RootNamespace>Fibonacci</RootNamespace>
|
||||||
|
<AssemblyName>Fibonacci</AssemblyName>
|
||||||
|
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
|
||||||
|
<FileAlignment>512</FileAlignment>
|
||||||
|
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||||
|
<Deterministic>true</Deterministic>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<Optimize>false</Optimize>
|
||||||
|
<OutputPath>bin\Debug\</OutputPath>
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
<WarningLevel>4</WarningLevel>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<OutputPath>bin\Release\</OutputPath>
|
||||||
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
<WarningLevel>4</WarningLevel>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Reference Include="System" />
|
||||||
|
<Reference Include="System.Core" />
|
||||||
|
<Reference Include="System.Xml.Linq" />
|
||||||
|
<Reference Include="System.Data.DataSetExtensions" />
|
||||||
|
<Reference Include="Microsoft.CSharp" />
|
||||||
|
<Reference Include="System.Data" />
|
||||||
|
<Reference Include="System.Net.Http" />
|
||||||
|
<Reference Include="System.Xml" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Compile Include="Program.cs" />
|
||||||
|
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="App.config" />
|
||||||
|
</ItemGroup>
|
||||||
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
|
</Project>
|
||||||
32
Fibonacci/Program.cs
Normal file
32
Fibonacci/Program.cs
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Fibonacci {
|
||||||
|
internal class Program {
|
||||||
|
public static ulong fibonacci(int darab) {
|
||||||
|
if ((darab == 0) || (darab == 1)) {
|
||||||
|
return Convert.ToUInt64(darab);
|
||||||
|
} else {
|
||||||
|
return fibonacci(darab - 1) + fibonacci(darab - 2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void Main(string[] args) {
|
||||||
|
Console.WriteLine("Adja meg hány számot akar látni");
|
||||||
|
ulong darab = Convert.ToUInt64(Console.ReadLine());
|
||||||
|
|
||||||
|
ulong a = 0, b = 1, szamlalo = 0;
|
||||||
|
while (szamlalo++ < darab) {
|
||||||
|
b += a;
|
||||||
|
a = b - a;
|
||||||
|
|
||||||
|
Console.WriteLine(b);
|
||||||
|
}
|
||||||
|
|
||||||
|
Console.ReadKey();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
36
Fibonacci/Properties/AssemblyInfo.cs
Normal file
36
Fibonacci/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
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("Fibonacci")]
|
||||||
|
[assembly: AssemblyDescription("")]
|
||||||
|
[assembly: AssemblyConfiguration("")]
|
||||||
|
[assembly: AssemblyCompany("")]
|
||||||
|
[assembly: AssemblyProduct("Fibonacci")]
|
||||||
|
[assembly: AssemblyCopyright("Copyright © 2022")]
|
||||||
|
[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("fae7220c-8e06-4d42-b54c-573a60584c51")]
|
||||||
|
|
||||||
|
// Version information for an assembly consists of the following four values:
|
||||||
|
//
|
||||||
|
// Major Version
|
||||||
|
// Minor Version
|
||||||
|
// Build Number
|
||||||
|
// Revision
|
||||||
|
//
|
||||||
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
|
// by using the '*' as shown below:
|
||||||
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
[assembly: AssemblyVersion("1.0.0.0")]
|
||||||
|
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||||
BIN
Fibonacci/bin/Debug/Fibonacci.exe
Normal file
BIN
Fibonacci/bin/Debug/Fibonacci.exe
Normal file
Binary file not shown.
6
Fibonacci/bin/Debug/Fibonacci.exe.config
Normal file
6
Fibonacci/bin/Debug/Fibonacci.exe.config
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
|
<configuration>
|
||||||
|
<startup>
|
||||||
|
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
|
||||||
|
</startup>
|
||||||
|
</configuration>
|
||||||
BIN
Fibonacci/bin/Debug/Fibonacci.pdb
Normal file
BIN
Fibonacci/bin/Debug/Fibonacci.pdb
Normal file
Binary file not shown.
@@ -0,0 +1,4 @@
|
|||||||
|
// <autogenerated />
|
||||||
|
using System;
|
||||||
|
using System.Reflection;
|
||||||
|
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")]
|
||||||
Binary file not shown.
BIN
Fibonacci/obj/Debug/Fibonacci.csproj.AssemblyReference.cache
Normal file
BIN
Fibonacci/obj/Debug/Fibonacci.csproj.AssemblyReference.cache
Normal file
Binary file not shown.
@@ -0,0 +1 @@
|
|||||||
|
7f4b213b428f4c013f19137338418ee1f5525793
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
C:\dev\c#\Fibonacci\bin\Debug\Fibonacci.exe.config
|
||||||
|
C:\dev\c#\Fibonacci\bin\Debug\Fibonacci.exe
|
||||||
|
C:\dev\c#\Fibonacci\bin\Debug\Fibonacci.pdb
|
||||||
|
C:\dev\c#\Fibonacci\obj\Debug\Fibonacci.csproj.AssemblyReference.cache
|
||||||
|
C:\dev\c#\Fibonacci\obj\Debug\Fibonacci.csproj.SuggestedBindingRedirects.cache
|
||||||
|
C:\dev\c#\Fibonacci\obj\Debug\Fibonacci.csproj.CoreCompileInputs.cache
|
||||||
|
C:\dev\c#\Fibonacci\obj\Debug\Fibonacci.exe
|
||||||
|
C:\dev\c#\Fibonacci\obj\Debug\Fibonacci.pdb
|
||||||
BIN
Fibonacci/obj/Debug/Fibonacci.exe
Normal file
BIN
Fibonacci/obj/Debug/Fibonacci.exe
Normal file
Binary file not shown.
BIN
Fibonacci/obj/Debug/Fibonacci.pdb
Normal file
BIN
Fibonacci/obj/Debug/Fibonacci.pdb
Normal file
Binary file not shown.
@@ -17,7 +17,7 @@ namespace ForAndForEach {
|
|||||||
for (int i = 0; i < list.Count; i++) {
|
for (int i = 0; i < list.Count; i++) {
|
||||||
Console.WriteLine(list[i]);
|
Console.WriteLine(list[i]);
|
||||||
}
|
}
|
||||||
Console.WriteLine();
|
Console.WriteLine("\nforeach:");
|
||||||
|
|
||||||
foreach(int i in list) {
|
foreach(int i in list) {
|
||||||
Console.WriteLine(i);
|
Console.WriteLine(i);
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -6,3 +6,11 @@ C:\dev\c#\c-sharp\ForAndForEach\obj\Debug\ForAndForEach.csproj.SuggestedBindingR
|
|||||||
C:\dev\c#\c-sharp\ForAndForEach\obj\Debug\ForAndForEach.csproj.CoreCompileInputs.cache
|
C:\dev\c#\c-sharp\ForAndForEach\obj\Debug\ForAndForEach.csproj.CoreCompileInputs.cache
|
||||||
C:\dev\c#\c-sharp\ForAndForEach\obj\Debug\ForAndForEach.exe
|
C:\dev\c#\c-sharp\ForAndForEach\obj\Debug\ForAndForEach.exe
|
||||||
C:\dev\c#\c-sharp\ForAndForEach\obj\Debug\ForAndForEach.pdb
|
C:\dev\c#\c-sharp\ForAndForEach\obj\Debug\ForAndForEach.pdb
|
||||||
|
C:\dev\c#\ForAndForEach\bin\Debug\ForAndForEach.exe.config
|
||||||
|
C:\dev\c#\ForAndForEach\bin\Debug\ForAndForEach.exe
|
||||||
|
C:\dev\c#\ForAndForEach\bin\Debug\ForAndForEach.pdb
|
||||||
|
C:\dev\c#\ForAndForEach\obj\Debug\ForAndForEach.csproj.AssemblyReference.cache
|
||||||
|
C:\dev\c#\ForAndForEach\obj\Debug\ForAndForEach.csproj.SuggestedBindingRedirects.cache
|
||||||
|
C:\dev\c#\ForAndForEach\obj\Debug\ForAndForEach.csproj.CoreCompileInputs.cache
|
||||||
|
C:\dev\c#\ForAndForEach\obj\Debug\ForAndForEach.exe
|
||||||
|
C:\dev\c#\ForAndForEach\obj\Debug\ForAndForEach.pdb
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -45,6 +45,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Elagazas", "Elagazas\Elagaz
|
|||||||
EndProject
|
EndProject
|
||||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ForAndForEach", "ForAndForEach\ForAndForEach.csproj", "{27F3C28C-7F88-42AC-9B27-5D69E35B6803}"
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ForAndForEach", "ForAndForEach\ForAndForEach.csproj", "{27F3C28C-7F88-42AC-9B27-5D69E35B6803}"
|
||||||
EndProject
|
EndProject
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Fibonacci", "Fibonacci\Fibonacci.csproj", "{FAE7220C-8E06-4D42-B54C-573A60584C51}"
|
||||||
|
EndProject
|
||||||
Global
|
Global
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
Debug|Any CPU = Debug|Any CPU
|
Debug|Any CPU = Debug|Any CPU
|
||||||
@@ -135,6 +137,10 @@ Global
|
|||||||
{27F3C28C-7F88-42AC-9B27-5D69E35B6803}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
{27F3C28C-7F88-42AC-9B27-5D69E35B6803}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
{27F3C28C-7F88-42AC-9B27-5D69E35B6803}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
{27F3C28C-7F88-42AC-9B27-5D69E35B6803}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
{27F3C28C-7F88-42AC-9B27-5D69E35B6803}.Release|Any CPU.Build.0 = Release|Any CPU
|
{27F3C28C-7F88-42AC-9B27-5D69E35B6803}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{FAE7220C-8E06-4D42-B54C-573A60584C51}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{FAE7220C-8E06-4D42-B54C-573A60584C51}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{FAE7220C-8E06-4D42-B54C-573A60584C51}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{FAE7220C-8E06-4D42-B54C-573A60584C51}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(SolutionProperties) = preSolution
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
HideSolutionNode = FALSE
|
HideSolutionNode = FALSE
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user