fajne rzeczy

This commit is contained in:
2026-03-17 14:20:45 +01:00
parent abd454ec61
commit cc1a7821d7
11 changed files with 77 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
#include <iostream>
class Student {
private:
std::string imie; // pole prywatne
int nrAlbumu; // pole prywatne
public:
Student(std::string imie, int nrAlbumu)
: imie(imie), nrAlbumu(nrAlbumu) {} // konstruktor
void pokaz() { // publiczna metoda
std::cout << imie << " " << nrAlbumu << std::endl;
}
};

View File

@@ -0,0 +1,3 @@
#include <iostream>
int main() {}

View File

@@ -0,0 +1,3 @@
#include <iostream>
int main() {}

View File

@@ -0,0 +1,15 @@
#include <iostream>
class Prostokat {
private:
int a;
int b;
public:
Prostokat(int x, int y) : a(x), b(y) {}
};
Prostokat p1;
Prostokat p2(2, 3);
Prostokat p3{4, 5};
int main() {}

View File

@@ -0,0 +1,15 @@
#include <iostream>
class Samochod {
private:
std::string marka;
int rok;
public:
Samochod(std::string m, int r) {
marka = m;
rok = r;
}
};
int main() {}

View File

@@ -0,0 +1,3 @@
#include <iostream>
int main() {}

View File

@@ -0,0 +1,17 @@
#include <iostream>
class Test {
public:
Test() { std::cout << "Konstruktor" << std::endl; }
~Test() { std::cout << "Destruktor" << std::endl; }
};
int main() {
std::cout << "Start" << std::endl;
Test a;
{
Test b;
std::cout << "Wewnatrz bloku" << std::endl;
}
std::cout << "Koniec" << std::endl;
}

View File

@@ -0,0 +1,3 @@
#include <iostream>
int main() {}

View File

@@ -0,0 +1,3 @@
#include <iostream>
int main() {}

View File

@@ -6,3 +6,4 @@ Postać standardowa funkcji boolowskiej może być sumacyjna lub iloczynowa, mog
[[Minimalizacja funkcji logicznych]]
[[Tablica Graya]]