Skip to content

Instantly share code, notes, and snippets.

View fxoz's full-sized avatar
🟡
Busy

Felix Orosz fxoz

🟡
Busy
View GitHub Profile
@fxoz
fxoz / planner.cpp
Created August 20, 2025 22:52
WiSe 2024-25 | Aufg. 6 | STL - ToDo-Liste
#include <algorithm>
#include <iostream>
#include <sstream>
#include <string>
#include <vector>
void organizeTasks() {
std::vector<std::tuple<std::string, int, std::string>> entries;
while (1) {
@fxoz
fxoz / anagramme.cpp
Created August 20, 2025 17:54
PE2 - 2025 Klausuraufgabe: Anagramme finden, Konsolen-Input, Output der Liste
#include <algorithm>
#include <iostream>
#include <string>
#include <vector>
std::string sortWord(std::string word) {
std::string out;
std::sort(word.begin(),word.end());
return word;
}
@fxoz
fxoz / artikel-sortieren.cpp
Created August 20, 2025 11:13
PE2 - WiSe 2024-25 Aufg. 2.2 | Set/Templates Aufgabe
#include <iostream>
#include <set>
template<typename T>
void printSet(const std::set<T>& mySet) {
for (const auto& ele : mySet) std::cout << ele << " ";
std::cout << "\n";
}
@fxoz
fxoz / uvicorn-ultra-performance.md
Last active August 16, 2025 12:25
Uvicorn 24x (realistically 10-12x) Performance Arguments (Windows 11, 12-thread CPU, Python 3.13)

uvicorn 24x (realistically 10-12x) Performance Arguments

uv run uvicorn main:app --log-level critical --workers 8 --http httptools --no-access-log --no-use-colors --proxy-headers

‼️Results may vary extremely depending on OS, hardware and various other factors.

‼️The benchmark I used ..\..\Downloads\hey.exe -n 1000 -z 5s http://127.0.0.1:8000 is quite theoretical and I used a very simple Hello world! script, see below.

@fxoz
fxoz / server.cpp
Created August 5, 2025 18:00
Simple Server C++
#include <iostream>
#include <unistd.h>
#include <arpa/inet.h>
#define MAX_BUFFER_SIZE 1024
#define PORT 8081
int main() {
std::cerr << "Hello!\n";
@fxoz
fxoz / wordcount.cpp
Created August 5, 2025 17:08
SoSe 23 Aufg. 6‼️Eingereicht von Tim
#include <iostream>
#include <map>
#include <algorithm>
#include <vector>
#include <sstream>
void wordcount(const std::string& text) {
std::stringstream ss(text);
std::map<std::string, unsigned> map;
@fxoz
fxoz / analyzeNumbers.cpp
Created August 5, 2025 16:26
WiSe 2023/24 - Aufg. 6‼️Eingereicht von Tim
#include <iostream>
#include <map>
#include <algorithm>
#include <sstream>
void analyzeNumbers() {
std::map<int, int> map{};
std::string input{};
try {
@fxoz
fxoz / produkt.cpp
Created August 5, 2025 16:23
WiSe 2023-24 - Aufg. 3 (Polymorphie) - Produktverwaltung
#include <iostream>
#include <string>
class Produkt {
protected:
int _id;
std::string _beschreibung;
double _preis;
public:
Produkt(int id, std::string beschr, double preis) : _id(id), _beschreibung(beschr), _preis(preis) {};
@fxoz
fxoz / cities.cpp
Created August 5, 2025 14:48
WiSe 2024-25 - Aufg. 4 I/O (Städte)
#include <fstream>
#include <iostream>
#include <string>
#include <vector>
#include <sstream>
long long printCitiesFromCountry(const std::string& filename, const std::string& country) {
std::ifstream file(filename);
if (!file) {
std::cerr << "File opening error\n";
@fxoz
fxoz / fahrzeuge.cpp
Last active August 5, 2025 14:17
WiSe 2024-25 - Aufgabe 3 (OOP) - Autos/Fahrzeuge/Garage
#include <iostream>
#include <vector>
#include <memory>
class Motor {
private:
int leistungPs;
std::string typ;
public:
Motor(int ps, const std::string& t) : leistungPs(ps), typ(t) {};