Description: This project contains a collection of simple coding exercises solved in both C# and Python. The goal is to compare the syntax and programming concepts of both languages. Each task is implemented in both C# and Python to highlight differences in syntax and approach.
Exercises (ENG)
Exercises (DE)
-
Install .NET SDK: Ensure that the .NET SDK is installed. You can download it from dotnet.microsoft.com.
-
Create a Project:
cd CodeComparison-CSharp-Python/CSharp dotnet new console -n <ProjectName>
-
Run the Program:
dotnet run --project <ProjectName>
-
Install Python: Ensure that Python is installed. You can download it from python.org.
-
Create a Virtual Environment:
cd CodeComparison-CSharp-Python/Python python -m venv venv
-
Activate the Virtual Environment:
- Windows:
.\venv\Scripts\Activate
- macOS/Linux:
source venv/bin/activate
- Windows:
-
Run the Program:
python <FileName>.py
CodeComparison-CSharp-Python/
│
├── CSharp/
│ ├── Basics/
│ │ ├── HelloWorld/
│ │ │ └── HelloWorld.cs
│ │ ├── Variables/
│ │ │ └── Variables.cs
│ │ ├── Conditionals/
│ │ │ └── Conditionals.cs
│ │ └── Loops/
│ │ └── Loops.cs
│ ├── DataStructures/
│ │ ├── Arrays/
│ │ │ └── Arrays.cs
│ │ ├── Lists/
│ │ │ └── Lists.cs
│ │ └── Dictionaries/
│ │ └── Dictionaries.cs
│ ├── Algorithms/
│ │ ├── Sorting/
│ │ │ └── Sorting.cs
│ │ ├── Searching/
│ │ │ └── Searching.cs
│ │ └── Recursion/
│ │ └── Recursion.cs
│ └── AdvancedTopicsMiscellaneous/
│ ├── OOP/
│ │ └── OOP.cs
│ ├── FileIO/
│ │ └── FileIO.cs
│ ├── ExceptionHandling/
│ │ └── ExceptionHandling.cs
│ ├── RegularExpressions/
│ │ └── RegularExpressions.cs
│ ├── DateAndTime/
│ │ └── DateAndTime.cs
│ ├── UnitTesting/
│ │ └── UnitTesting.cs
│ └── WebScraping/
│ └── WebScraping.cs
│ └── README.md
│
├── Python/
│ ├── Basics/
│ │ ├── HelloWorld/
│ │ │ └── HelloWorld.py
│ │ ├── Variables/
│ │ │ └── Variables.py
│ │ ├── Conditionals/
│ │ │ └── Conditionals.py
│ │ └── Loops/
│ │ └── Loops.py
│ ├── DataStructures/
│ │ ├── Arrays/
│ │ │ └── Arrays.py
│ │ ├── Lists/
│ │ │ └── Lists.py
│ │ └── Dictionaries/
│ │ └── Dictionaries.py
│ ├── Algorithms/
│ │ ├── Sorting/
│ │ │ └── Sorting.py
│ │ ├── Searching/
│ │ │ └── Searching.py
│ │ └── Recursion/
│ │ └── Recursion.py
│ └── AdvancedTopicsMiscellaneous/
│ ├── OOP/
│ │ └── OOP.py
│ ├── FileIO/
│ │ └── FileIO.py
│ ├── ExceptionHandling/
│ │ └── ExceptionHandling.py
│ ├── RegularExpressions/
│ │ └── RegularExpressions.py
│ ├── DateAndTime/
│ │ └── DateAndTime.py
│ ├── UnitTesting/
│ │ └── UnitTesting.py
│ └── WebScraping/
│ └── WebScraping.py
│ └── README.md
│
└── README.md
You are welcome to contribute to this project! If you want to add a new exercise or suggest improvements, please create a pull request.