This commit is contained in:
jakub
2026-01-13 00:24:42 +01:00
parent 4ff7a7c3b1
commit f0ebb9cf18
18 changed files with 3123 additions and 0 deletions

View File

@@ -0,0 +1,59 @@
<?php
?>
<!doctype html>
<html lang="pl">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Z35 - Proste prostopadłe</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Zadanie Z35</h1>
<h2>Autor: Jakub Grzegorczyk</h2>
</header>
<div class="box">
<p>Napisz program, który dla podanych dwóch równań prostych odpowie czy proste te są prostopadłe.</p>
</div>
<div class="box">
<form action="index.php" method="post">
<fieldset>
<legend>Współczynniki: </legend>
<label for="a1">Współczynnik a<sub>1</sub>:</label>
<input type="number" name="a1" id="a1">
<label for="b1">Współczynnik b<sub>1</sub>:</label>
<input type="number" name="b1" id="b1">
<label for="a2">Współczynnik a<sub>2</sub>:</label>
<input type="number" name="a2" id="a2">
<label for="b2">Współczynnik b<sub>2</sub>:</label>
<input type="number" name="b2" id="b2">
</fieldset>
<button type="submit">Sprawdź równoległość</button>
</form>
</div>
<?php
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$a1 = $_POST['a1'];
$b1 = $_POST['b1'];
$a2 = $_POST['a2'];
$b2 = $_POST['b2'];
echo "<div class='box'>";
echo "<p>a<sub>1</sub> = {$a1}<br>b<sub>1</sub> = {$b1}<br>a<sub>2</sub> = {$a2}<br>b<sub>2</sub> = {$b2}</p>";
echo "<p>f(x) = a<sub>1</sub>x + b<sub>1</sub> = {$a1}x + {$b1}</p>";
echo "<p>f(x) = a<sub>2</sub>x + b<sub>2</sub> = {$a2}x + {$b2}</p>";
if ($a1 * $a2 == -1) {
echo "<p style='color: green; font-weight: bold;'>Proste są prostopadłe.</p>";
} else {
echo "<p style='color: red; font-weight: bold;'>Proste NIE są prostopadłe.</p>";
}
echo "</div>";
}
?>
</body>
</html>

View File

@@ -0,0 +1,299 @@
/* === UNIVERSAL SCHOOL TEMPLATE CSS (BLACK & WHITE EDITION) === */
/* clean, modern, and copy-paste friendly for all projects */
/* === RESET === */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
/* === VARIABLES === */
:root {
--accent: #000;
--border: #000;
--bg: #fff;
--bg-alt: #f7f7f7;
--text: #111;
--shadow: rgba(0, 0, 0, 0.15) 3px 3px 6px;
--radius: 1em;
--max-width: 1300px;
}
/* === PAGE === */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Verdana, sans-serif;
background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
color: var(--text);
display: flex;
flex-direction: column;
align-items: center;
min-height: 100vh;
line-height: 1.6;
}
/* === HEADER === */
header {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 20px 30px;
box-shadow: var(--shadow);
background: var(--bg);
width: 95%;
max-width: var(--max-width);
text-align: center;
margin-top: 25px;
transition: box-shadow 0.3s ease, transform 0.2s ease;
}
header:hover {
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
transform: translateY(-2px);
}
header h1 {
font-size: 2.2rem;
}
header h2 {
margin-top: 0.5rem;
font-weight: 400;
font-size: 1.1rem;
color: #444;
}
/* === BOX === */
.box {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 25px 35px;
margin-top: 25px;
background: var(--bg);
box-shadow: var(--shadow);
width: 95%;
max-width: var(--max-width);
transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.box:hover {
transform: translateY(-2px);
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
}
/* === TEXT ELEMENTS === */
p {
margin-bottom: 1rem;
}
.box > p:last-child {
margin-bottom: 0;
}
h1, h2, h3, h4 {
margin-bottom: 0.5rem;
font-weight: 600;
}
a {
color: #000;
text-decoration: underline;
font-weight: 500;
}
a:hover {
opacity: 0.7;
}
/* === LISTS === */
ul, ol {
margin: 1rem 0 1rem 1.5rem;
}
li {
margin-bottom: 0.4rem;
}
/* === TABLES === */
table {
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
background: var(--bg);
border: 2px solid var(--border);
border-radius: 0.6em;
overflow: hidden;
box-shadow: var(--shadow);
}
th, td {
padding: 10px 12px;
border-bottom: 1px solid #ccc;
}
th {
background: var(--bg-alt);
font-weight: bold;
text-align: left;
}
tr:hover {
background: #f2f2f2;
}
/* === FORMS === */
form {
display: flex;
flex-direction: column;
gap: 1.4rem;
}
.box:has(> form) {
padding: 35px 35px;
}
fieldset {
border: 2px solid var(--border);
border-radius: 0.8em;
padding: 1.2rem 1.5rem;
background: var(--bg-alt);
}
legend {
font-weight: bold;
color: #000;
padding: 0 0.4rem;
font-size: 1.05rem;
}
label {
font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
width: 100%;
font-size: 1rem;
margin-top: 6px;
margin-bottom: 8px;
border: 2px solid var(--border);
border-radius: 0.5em;
padding: 0.4rem 0.5rem;
transition: all 0.2s ease;
background: var(--bg);
}
textarea {
resize: vertical;
min-height: 100px;
}
input:focus,
textarea:focus,
select:focus {
outline: none;
border-color: #000;
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
background: #f9f9f9;
}
input[type="radio"],
input[type="checkbox"] {
accent-color: #000;
transform: scale(1.2);
margin-right: 0.3rem;
}
/* === BUTTONS === */
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
padding: 10px 20px;
border: 2px solid var(--border);
border-radius: 0.5em;
font-weight: bold;
font-size: 1rem;
background: linear-gradient(180deg, #fff 0%, #f2f2f2 100%);
cursor: pointer;
transition: all 0.2s ease;
align-self: flex-start;
}
button {
width: 100%;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
background: #eaeaea;
box-shadow: rgba(0, 0, 0, 0.25) 3px 3px 6px;
transform: translateY(-2px);
}
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
transform: translateY(0);
box-shadow: rgba(0, 0, 0, 0.15) 1px 1px 3px;
background: #f7f7f7;
}
/* === HR, CODE, ETC. === */
hr {
border: 0;
border-top: 2px solid var(--border);
margin: 1.5rem 0;
}
img {
max-width: 100%;
border-radius: 0.5em;
}
code, pre {
background: #f4f4f4;
border: 1px solid #ccc;
border-radius: 0.4em;
padding: 0.3em 0.5em;
font-family: "Courier New", monospace;
}
pre {
padding: 1em;
overflow-x: auto;
}
/* === RESPONSIVE === */
@media (max-width: 900px) {
header, .box {
width: 95%;
padding: 20px;
}
button {
width: 100%;
}
textarea {
width: 100%;
}
}
@media (max-width: 600px) {
header h1 {
font-size: 1.7rem;
}
header h2 {
font-size: 0.95rem;
}
}

View File

@@ -0,0 +1,48 @@
<?php
?>
<!doctype html>
<html lang="pl">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Z36 - Podzielność liczb</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Zadanie Z36</h1>
<h2>Autor: Jakub Grzegorczyk</h2>
</header>
<div class="box">
<p>Napisz program, który: dla liczb całkowitych (program powinien sprawdzić, czy liczby są całkowite) A i B sprawdza czy A jest podzielne przez B (wykorzystaj funkcję zwracającą resztę z dzielenia).</p>
</div>
<div class="box">
<form action="index.php" method="post">
<fieldset>
<label for="a">Podaj A:</label>
<input type="number" name="a" id="a" required>
<label for="b">Podaj B:</label>
<input type="number" name="b" id="b" required>
</fieldset>
<button type="submit">Wyślij</button>
</form>
</div>
<?php
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$a = htmlspecialchars($_POST['a']);
$b = htmlspecialchars($_POST['b']);
echo '<div class="box">';
echo "a = $a<br>";
echo "b = $b<br>";
if ($a % $b == 0) {
echo "Liczba $a jest podzielna przez $b";
} else {
echo "Liczba $a nie jest podzielna przez $b";
}
echo '</div>';
}
?>
</body>
</html>

View File

@@ -0,0 +1,299 @@
/* === UNIVERSAL SCHOOL TEMPLATE CSS (BLACK & WHITE EDITION) === */
/* clean, modern, and copy-paste friendly for all projects */
/* === RESET === */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
/* === VARIABLES === */
:root {
--accent: #000;
--border: #000;
--bg: #fff;
--bg-alt: #f7f7f7;
--text: #111;
--shadow: rgba(0, 0, 0, 0.15) 3px 3px 6px;
--radius: 1em;
--max-width: 1300px;
}
/* === PAGE === */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Verdana, sans-serif;
background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
color: var(--text);
display: flex;
flex-direction: column;
align-items: center;
min-height: 100vh;
line-height: 1.6;
}
/* === HEADER === */
header {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 20px 30px;
box-shadow: var(--shadow);
background: var(--bg);
width: 95%;
max-width: var(--max-width);
text-align: center;
margin-top: 25px;
transition: box-shadow 0.3s ease, transform 0.2s ease;
}
header:hover {
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
transform: translateY(-2px);
}
header h1 {
font-size: 2.2rem;
}
header h2 {
margin-top: 0.5rem;
font-weight: 400;
font-size: 1.1rem;
color: #444;
}
/* === BOX === */
.box {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 25px 35px;
margin-top: 25px;
background: var(--bg);
box-shadow: var(--shadow);
width: 95%;
max-width: var(--max-width);
transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.box:hover {
transform: translateY(-2px);
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
}
/* === TEXT ELEMENTS === */
p {
margin-bottom: 1rem;
}
.box > p:last-child {
margin-bottom: 0;
}
h1, h2, h3, h4 {
margin-bottom: 0.5rem;
font-weight: 600;
}
a {
color: #000;
text-decoration: underline;
font-weight: 500;
}
a:hover {
opacity: 0.7;
}
/* === LISTS === */
ul, ol {
margin: 1rem 0 1rem 1.5rem;
}
li {
margin-bottom: 0.4rem;
}
/* === TABLES === */
table {
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
background: var(--bg);
border: 2px solid var(--border);
border-radius: 0.6em;
overflow: hidden;
box-shadow: var(--shadow);
}
th, td {
padding: 10px 12px;
border-bottom: 1px solid #ccc;
}
th {
background: var(--bg-alt);
font-weight: bold;
text-align: left;
}
tr:hover {
background: #f2f2f2;
}
/* === FORMS === */
form {
display: flex;
flex-direction: column;
gap: 1.4rem;
}
.box:has(> form) {
padding: 35px 35px;
}
fieldset {
border: 2px solid var(--border);
border-radius: 0.8em;
padding: 1.2rem 1.5rem;
background: var(--bg-alt);
}
legend {
font-weight: bold;
color: #000;
padding: 0 0.4rem;
font-size: 1.05rem;
}
label {
font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
width: 100%;
font-size: 1rem;
margin-top: 6px;
margin-bottom: 8px;
border: 2px solid var(--border);
border-radius: 0.5em;
padding: 0.4rem 0.5rem;
transition: all 0.2s ease;
background: var(--bg);
}
textarea {
resize: vertical;
min-height: 100px;
}
input:focus,
textarea:focus,
select:focus {
outline: none;
border-color: #000;
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
background: #f9f9f9;
}
input[type="radio"],
input[type="checkbox"] {
accent-color: #000;
transform: scale(1.2);
margin-right: 0.3rem;
}
/* === BUTTONS === */
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
padding: 10px 20px;
border: 2px solid var(--border);
border-radius: 0.5em;
font-weight: bold;
font-size: 1rem;
background: linear-gradient(180deg, #fff 0%, #f2f2f2 100%);
cursor: pointer;
transition: all 0.2s ease;
align-self: flex-start;
}
button {
width: 100%;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
background: #eaeaea;
box-shadow: rgba(0, 0, 0, 0.25) 3px 3px 6px;
transform: translateY(-2px);
}
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
transform: translateY(0);
box-shadow: rgba(0, 0, 0, 0.15) 1px 1px 3px;
background: #f7f7f7;
}
/* === HR, CODE, ETC. === */
hr {
border: 0;
border-top: 2px solid var(--border);
margin: 1.5rem 0;
}
img {
max-width: 100%;
border-radius: 0.5em;
}
code, pre {
background: #f4f4f4;
border: 1px solid #ccc;
border-radius: 0.4em;
padding: 0.3em 0.5em;
font-family: "Courier New", monospace;
}
pre {
padding: 1em;
overflow-x: auto;
}
/* === RESPONSIVE === */
@media (max-width: 900px) {
header, .box {
width: 95%;
padding: 20px;
}
button {
width: 100%;
}
textarea {
width: 100%;
}
}
@media (max-width: 600px) {
header h1 {
font-size: 1.7rem;
}
header h2 {
font-size: 0.95rem;
}
}

View File

@@ -0,0 +1,43 @@
<?php
?>
<!doctype html>
<html lang="pl">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Z37 - Wartość bezwzględna</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Zadanie Z37</h1>
<h2>Autor: Jakub Grzegorczyk</h2>
</header>
<div class="box">
<p>Napisz program, który dla liczby A oblicza jej wartość bezwzględną (nie używaj wbudowanej funkcji matematycznej).</p>
</div>
<div class="box">
<form action="index.php" method="post">
<fieldset>
<label for="a">Wartość A:</label>
<input type="number" name="a" id="a">
</fieldset>
<button type="submit">Wyślij</button>
</form>
</div>
<?php
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$a = htmlspecialchars($_POST['a']);
echo "<div class='box'>";
echo "A = {$a}<br>";
if ($a < 0) {
$a = -$a;
}
echo "Wartość bezwzględna liczby A: {$a}";
echo '</div>';
}
?>
</body>
</html>

View File

@@ -0,0 +1,299 @@
/* === UNIVERSAL SCHOOL TEMPLATE CSS (BLACK & WHITE EDITION) === */
/* clean, modern, and copy-paste friendly for all projects */
/* === RESET === */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
/* === VARIABLES === */
:root {
--accent: #000;
--border: #000;
--bg: #fff;
--bg-alt: #f7f7f7;
--text: #111;
--shadow: rgba(0, 0, 0, 0.15) 3px 3px 6px;
--radius: 1em;
--max-width: 1300px;
}
/* === PAGE === */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Verdana, sans-serif;
background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
color: var(--text);
display: flex;
flex-direction: column;
align-items: center;
min-height: 100vh;
line-height: 1.6;
}
/* === HEADER === */
header {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 20px 30px;
box-shadow: var(--shadow);
background: var(--bg);
width: 95%;
max-width: var(--max-width);
text-align: center;
margin-top: 25px;
transition: box-shadow 0.3s ease, transform 0.2s ease;
}
header:hover {
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
transform: translateY(-2px);
}
header h1 {
font-size: 2.2rem;
}
header h2 {
margin-top: 0.5rem;
font-weight: 400;
font-size: 1.1rem;
color: #444;
}
/* === BOX === */
.box {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 25px 35px;
margin-top: 25px;
background: var(--bg);
box-shadow: var(--shadow);
width: 95%;
max-width: var(--max-width);
transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.box:hover {
transform: translateY(-2px);
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
}
/* === TEXT ELEMENTS === */
p {
margin-bottom: 1rem;
}
.box > p:last-child {
margin-bottom: 0;
}
h1, h2, h3, h4 {
margin-bottom: 0.5rem;
font-weight: 600;
}
a {
color: #000;
text-decoration: underline;
font-weight: 500;
}
a:hover {
opacity: 0.7;
}
/* === LISTS === */
ul, ol {
margin: 1rem 0 1rem 1.5rem;
}
li {
margin-bottom: 0.4rem;
}
/* === TABLES === */
table {
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
background: var(--bg);
border: 2px solid var(--border);
border-radius: 0.6em;
overflow: hidden;
box-shadow: var(--shadow);
}
th, td {
padding: 10px 12px;
border-bottom: 1px solid #ccc;
}
th {
background: var(--bg-alt);
font-weight: bold;
text-align: left;
}
tr:hover {
background: #f2f2f2;
}
/* === FORMS === */
form {
display: flex;
flex-direction: column;
gap: 1.4rem;
}
.box:has(> form) {
padding: 35px 35px;
}
fieldset {
border: 2px solid var(--border);
border-radius: 0.8em;
padding: 1.2rem 1.5rem;
background: var(--bg-alt);
}
legend {
font-weight: bold;
color: #000;
padding: 0 0.4rem;
font-size: 1.05rem;
}
label {
font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
width: 100%;
font-size: 1rem;
margin-top: 6px;
margin-bottom: 8px;
border: 2px solid var(--border);
border-radius: 0.5em;
padding: 0.4rem 0.5rem;
transition: all 0.2s ease;
background: var(--bg);
}
textarea {
resize: vertical;
min-height: 100px;
}
input:focus,
textarea:focus,
select:focus {
outline: none;
border-color: #000;
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
background: #f9f9f9;
}
input[type="radio"],
input[type="checkbox"] {
accent-color: #000;
transform: scale(1.2);
margin-right: 0.3rem;
}
/* === BUTTONS === */
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
padding: 10px 20px;
border: 2px solid var(--border);
border-radius: 0.5em;
font-weight: bold;
font-size: 1rem;
background: linear-gradient(180deg, #fff 0%, #f2f2f2 100%);
cursor: pointer;
transition: all 0.2s ease;
align-self: flex-start;
}
button {
width: 100%;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
background: #eaeaea;
box-shadow: rgba(0, 0, 0, 0.25) 3px 3px 6px;
transform: translateY(-2px);
}
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
transform: translateY(0);
box-shadow: rgba(0, 0, 0, 0.15) 1px 1px 3px;
background: #f7f7f7;
}
/* === HR, CODE, ETC. === */
hr {
border: 0;
border-top: 2px solid var(--border);
margin: 1.5rem 0;
}
img {
max-width: 100%;
border-radius: 0.5em;
}
code, pre {
background: #f4f4f4;
border: 1px solid #ccc;
border-radius: 0.4em;
padding: 0.3em 0.5em;
font-family: "Courier New", monospace;
}
pre {
padding: 1em;
overflow-x: auto;
}
/* === RESPONSIVE === */
@media (max-width: 900px) {
header, .box {
width: 95%;
padding: 20px;
}
button {
width: 100%;
}
textarea {
width: 100%;
}
}
@media (max-width: 600px) {
header h1 {
font-size: 1.7rem;
}
header h2 {
font-size: 0.95rem;
}
}

View File

@@ -0,0 +1,49 @@
<?php
?>
<!doctype html>
<html lang="pl">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Z38 - Wieksze lub równe</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Zadanie Z38</h1>
<h2>Autor: Jakub Grzegorczyk</h2>
</header>
<div class="box">
<p>Napisz program, który: dla liczby całkowitych (program sprawdza, czy podane liczny są całkowite) A i B wyświetla, która z nich jest większa lub czy są równe.</p>
</div>
<div class="box">
<form action="index.php" method="post">
<fieldset>
<label for="a">Podaj A:</label>
<input type="number" name="a" id="a" required>
<label for="b">Podaj B:</label>
<input type="number" name="b" id="b" required>
</fieldset>
<button type="submit">Wyślij</button>
</form>
</div>
<?php
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$a = (int)$_POST['a'];
$b = (int)$_POST['b'];
echo "<div class='box'>";
echo "A: $a<br>B: $b<br>";
if ($a > $b) {
echo "Liczba {$a} jest wieksza od {$b}";
} elseif ($a == $b) {
echo "Liczby są równe";
} else {
echo "Liczba {$b} jest wieksza od {$a}";
}
echo "</div>";
}
?>
</body>
</html>

View File

@@ -0,0 +1,299 @@
/* === UNIVERSAL SCHOOL TEMPLATE CSS (BLACK & WHITE EDITION) === */
/* clean, modern, and copy-paste friendly for all projects */
/* === RESET === */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
/* === VARIABLES === */
:root {
--accent: #000;
--border: #000;
--bg: #fff;
--bg-alt: #f7f7f7;
--text: #111;
--shadow: rgba(0, 0, 0, 0.15) 3px 3px 6px;
--radius: 1em;
--max-width: 1300px;
}
/* === PAGE === */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Verdana, sans-serif;
background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
color: var(--text);
display: flex;
flex-direction: column;
align-items: center;
min-height: 100vh;
line-height: 1.6;
}
/* === HEADER === */
header {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 20px 30px;
box-shadow: var(--shadow);
background: var(--bg);
width: 95%;
max-width: var(--max-width);
text-align: center;
margin-top: 25px;
transition: box-shadow 0.3s ease, transform 0.2s ease;
}
header:hover {
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
transform: translateY(-2px);
}
header h1 {
font-size: 2.2rem;
}
header h2 {
margin-top: 0.5rem;
font-weight: 400;
font-size: 1.1rem;
color: #444;
}
/* === BOX === */
.box {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 25px 35px;
margin-top: 25px;
background: var(--bg);
box-shadow: var(--shadow);
width: 95%;
max-width: var(--max-width);
transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.box:hover {
transform: translateY(-2px);
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
}
/* === TEXT ELEMENTS === */
p {
margin-bottom: 1rem;
}
.box > p:last-child {
margin-bottom: 0;
}
h1, h2, h3, h4 {
margin-bottom: 0.5rem;
font-weight: 600;
}
a {
color: #000;
text-decoration: underline;
font-weight: 500;
}
a:hover {
opacity: 0.7;
}
/* === LISTS === */
ul, ol {
margin: 1rem 0 1rem 1.5rem;
}
li {
margin-bottom: 0.4rem;
}
/* === TABLES === */
table {
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
background: var(--bg);
border: 2px solid var(--border);
border-radius: 0.6em;
overflow: hidden;
box-shadow: var(--shadow);
}
th, td {
padding: 10px 12px;
border-bottom: 1px solid #ccc;
}
th {
background: var(--bg-alt);
font-weight: bold;
text-align: left;
}
tr:hover {
background: #f2f2f2;
}
/* === FORMS === */
form {
display: flex;
flex-direction: column;
gap: 1.4rem;
}
.box:has(> form) {
padding: 35px 35px;
}
fieldset {
border: 2px solid var(--border);
border-radius: 0.8em;
padding: 1.2rem 1.5rem;
background: var(--bg-alt);
}
legend {
font-weight: bold;
color: #000;
padding: 0 0.4rem;
font-size: 1.05rem;
}
label {
font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
width: 100%;
font-size: 1rem;
margin-top: 6px;
margin-bottom: 8px;
border: 2px solid var(--border);
border-radius: 0.5em;
padding: 0.4rem 0.5rem;
transition: all 0.2s ease;
background: var(--bg);
}
textarea {
resize: vertical;
min-height: 100px;
}
input:focus,
textarea:focus,
select:focus {
outline: none;
border-color: #000;
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
background: #f9f9f9;
}
input[type="radio"],
input[type="checkbox"] {
accent-color: #000;
transform: scale(1.2);
margin-right: 0.3rem;
}
/* === BUTTONS === */
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
padding: 10px 20px;
border: 2px solid var(--border);
border-radius: 0.5em;
font-weight: bold;
font-size: 1rem;
background: linear-gradient(180deg, #fff 0%, #f2f2f2 100%);
cursor: pointer;
transition: all 0.2s ease;
align-self: flex-start;
}
button {
width: 100%;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
background: #eaeaea;
box-shadow: rgba(0, 0, 0, 0.25) 3px 3px 6px;
transform: translateY(-2px);
}
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
transform: translateY(0);
box-shadow: rgba(0, 0, 0, 0.15) 1px 1px 3px;
background: #f7f7f7;
}
/* === HR, CODE, ETC. === */
hr {
border: 0;
border-top: 2px solid var(--border);
margin: 1.5rem 0;
}
img {
max-width: 100%;
border-radius: 0.5em;
}
code, pre {
background: #f4f4f4;
border: 1px solid #ccc;
border-radius: 0.4em;
padding: 0.3em 0.5em;
font-family: "Courier New", monospace;
}
pre {
padding: 1em;
overflow-x: auto;
}
/* === RESPONSIVE === */
@media (max-width: 900px) {
header, .box {
width: 95%;
padding: 20px;
}
button {
width: 100%;
}
textarea {
width: 100%;
}
}
@media (max-width: 600px) {
header h1 {
font-size: 1.7rem;
}
header h2 {
font-size: 0.95rem;
}
}

View File

@@ -0,0 +1,48 @@
<?php
?>
<!doctype html>
<html lang="pl">
<head>
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<meta charset="UTF-8">
<title>Z39 - Tak, Nie</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Zadanie Z39</h1>
<h2>Autor: Jakub Grzegorczyk</h2>
</header>
<div class="box">
<p>Napisz program, który Czyta wprowadzony znak z klawiatury i na „t” lub „T” wyświetla „TAK” na „n” lub „N” wyświetla „NIE” - na pozostałe znaki nie reaguję.</p>
</div>
<div class="box">
<form action="index.php" method="post">
<fieldset>
<label for="x">Podaj znak:</label>
<input type="text" required name="x" id="x">
</fieldset>
<button type="submit">Wyślij</button>
</form>
</div>
<?php
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$x = htmlspecialchars($_POST['x']);
if (strlen($x) != 1) { return; }
if ($x == 't' || $x == 'T' || $x == 'n' || $x == 'N') {
echo '<div class="box">';
if ($x == 't' || $x == 'T') {
echo 'TAK';
} else if ($x == 'n' || $x == 'N') {
echo 'NIE';
}
echo '</div>';
}
}
?>
</body>
</html>

View File

@@ -0,0 +1,299 @@
/* === UNIVERSAL SCHOOL TEMPLATE CSS (BLACK & WHITE EDITION) === */
/* clean, modern, and copy-paste friendly for all projects */
/* === RESET === */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
/* === VARIABLES === */
:root {
--accent: #000;
--border: #000;
--bg: #fff;
--bg-alt: #f7f7f7;
--text: #111;
--shadow: rgba(0, 0, 0, 0.15) 3px 3px 6px;
--radius: 1em;
--max-width: 1300px;
}
/* === PAGE === */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Verdana, sans-serif;
background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
color: var(--text);
display: flex;
flex-direction: column;
align-items: center;
min-height: 100vh;
line-height: 1.6;
}
/* === HEADER === */
header {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 20px 30px;
box-shadow: var(--shadow);
background: var(--bg);
width: 95%;
max-width: var(--max-width);
text-align: center;
margin-top: 25px;
transition: box-shadow 0.3s ease, transform 0.2s ease;
}
header:hover {
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
transform: translateY(-2px);
}
header h1 {
font-size: 2.2rem;
}
header h2 {
margin-top: 0.5rem;
font-weight: 400;
font-size: 1.1rem;
color: #444;
}
/* === BOX === */
.box {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 25px 35px;
margin-top: 25px;
background: var(--bg);
box-shadow: var(--shadow);
width: 95%;
max-width: var(--max-width);
transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.box:hover {
transform: translateY(-2px);
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
}
/* === TEXT ELEMENTS === */
p {
margin-bottom: 1rem;
}
.box > p:last-child {
margin-bottom: 0;
}
h1, h2, h3, h4 {
margin-bottom: 0.5rem;
font-weight: 600;
}
a {
color: #000;
text-decoration: underline;
font-weight: 500;
}
a:hover {
opacity: 0.7;
}
/* === LISTS === */
ul, ol {
margin: 1rem 0 1rem 1.5rem;
}
li {
margin-bottom: 0.4rem;
}
/* === TABLES === */
table {
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
background: var(--bg);
border: 2px solid var(--border);
border-radius: 0.6em;
overflow: hidden;
box-shadow: var(--shadow);
}
th, td {
padding: 10px 12px;
border-bottom: 1px solid #ccc;
}
th {
background: var(--bg-alt);
font-weight: bold;
text-align: left;
}
tr:hover {
background: #f2f2f2;
}
/* === FORMS === */
form {
display: flex;
flex-direction: column;
gap: 1.4rem;
}
.box:has(> form) {
padding: 35px 35px;
}
fieldset {
border: 2px solid var(--border);
border-radius: 0.8em;
padding: 1.2rem 1.5rem;
background: var(--bg-alt);
}
legend {
font-weight: bold;
color: #000;
padding: 0 0.4rem;
font-size: 1.05rem;
}
label {
font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
width: 100%;
font-size: 1rem;
margin-top: 6px;
margin-bottom: 8px;
border: 2px solid var(--border);
border-radius: 0.5em;
padding: 0.4rem 0.5rem;
transition: all 0.2s ease;
background: var(--bg);
}
textarea {
resize: vertical;
min-height: 100px;
}
input:focus,
textarea:focus,
select:focus {
outline: none;
border-color: #000;
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
background: #f9f9f9;
}
input[type="radio"],
input[type="checkbox"] {
accent-color: #000;
transform: scale(1.2);
margin-right: 0.3rem;
}
/* === BUTTONS === */
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
padding: 10px 20px;
border: 2px solid var(--border);
border-radius: 0.5em;
font-weight: bold;
font-size: 1rem;
background: linear-gradient(180deg, #fff 0%, #f2f2f2 100%);
cursor: pointer;
transition: all 0.2s ease;
align-self: flex-start;
}
button {
width: 100%;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
background: #eaeaea;
box-shadow: rgba(0, 0, 0, 0.25) 3px 3px 6px;
transform: translateY(-2px);
}
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
transform: translateY(0);
box-shadow: rgba(0, 0, 0, 0.15) 1px 1px 3px;
background: #f7f7f7;
}
/* === HR, CODE, ETC. === */
hr {
border: 0;
border-top: 2px solid var(--border);
margin: 1.5rem 0;
}
img {
max-width: 100%;
border-radius: 0.5em;
}
code, pre {
background: #f4f4f4;
border: 1px solid #ccc;
border-radius: 0.4em;
padding: 0.3em 0.5em;
font-family: "Courier New", monospace;
}
pre {
padding: 1em;
overflow-x: auto;
}
/* === RESPONSIVE === */
@media (max-width: 900px) {
header, .box {
width: 95%;
padding: 20px;
}
button {
width: 100%;
}
textarea {
width: 100%;
}
}
@media (max-width: 600px) {
header h1 {
font-size: 1.7rem;
}
header h2 {
font-size: 0.95rem;
}
}

View File

@@ -0,0 +1,43 @@
<?php
?>
<!doctype html>
<html lang="pl">
<head>
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<meta charset="UTF-8">
<title>Z40 - Zupa</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Zadanie Z40</h1>
<h2>Autor: Jakub Grzegorczyk</h2>
</header>
<div class="box">
<p>Napisz program, który pyta o nazwę zupy jeśli zupa to „grzybowa” lub „grochowa” (niezależnie od wielkości użytych znaków) odpowiada, że lubi te zupę. W innym przypadku odpowiada, że nie lubi tej zupy wykorzystując w odpowiedzi jej nazwę np. Zupa pomidorowa nie lubię tej zupy!!!</p>
</div>
<div class="box">
<form action="index.php" method="post">
<fieldset>
<label for="nazwaZupy">Wpisz nazwę zupy</label>
<input type="text" name="nazwaZupy" id="nazwaZupy">
</fieldset>
<button type="submit">Wyślij</button>
</form>
</div>
<?php
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$nazwaZupy = htmlspecialchars(strtolower($_POST['nazwaZupy']));
echo '<div class="box">';
if ($nazwaZupy == 'grzybowa' || $nazwaZupy == 'grochowa') {
echo "Lubię tę zupę";
} else {
echo "Zupa $nazwaZupy - nie lubię tej zupy!!!";
}
echo '</div>';
}
?>
</body>
</html>

View File

@@ -0,0 +1,299 @@
/* === UNIVERSAL SCHOOL TEMPLATE CSS (BLACK & WHITE EDITION) === */
/* clean, modern, and copy-paste friendly for all projects */
/* === RESET === */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
/* === VARIABLES === */
:root {
--accent: #000;
--border: #000;
--bg: #fff;
--bg-alt: #f7f7f7;
--text: #111;
--shadow: rgba(0, 0, 0, 0.15) 3px 3px 6px;
--radius: 1em;
--max-width: 1300px;
}
/* === PAGE === */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Verdana, sans-serif;
background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
color: var(--text);
display: flex;
flex-direction: column;
align-items: center;
min-height: 100vh;
line-height: 1.6;
}
/* === HEADER === */
header {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 20px 30px;
box-shadow: var(--shadow);
background: var(--bg);
width: 95%;
max-width: var(--max-width);
text-align: center;
margin-top: 25px;
transition: box-shadow 0.3s ease, transform 0.2s ease;
}
header:hover {
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
transform: translateY(-2px);
}
header h1 {
font-size: 2.2rem;
}
header h2 {
margin-top: 0.5rem;
font-weight: 400;
font-size: 1.1rem;
color: #444;
}
/* === BOX === */
.box {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 25px 35px;
margin-top: 25px;
background: var(--bg);
box-shadow: var(--shadow);
width: 95%;
max-width: var(--max-width);
transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.box:hover {
transform: translateY(-2px);
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
}
/* === TEXT ELEMENTS === */
p {
margin-bottom: 1rem;
}
.box > p:last-child {
margin-bottom: 0;
}
h1, h2, h3, h4 {
margin-bottom: 0.5rem;
font-weight: 600;
}
a {
color: #000;
text-decoration: underline;
font-weight: 500;
}
a:hover {
opacity: 0.7;
}
/* === LISTS === */
ul, ol {
margin: 1rem 0 1rem 1.5rem;
}
li {
margin-bottom: 0.4rem;
}
/* === TABLES === */
table {
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
background: var(--bg);
border: 2px solid var(--border);
border-radius: 0.6em;
overflow: hidden;
box-shadow: var(--shadow);
}
th, td {
padding: 10px 12px;
border-bottom: 1px solid #ccc;
}
th {
background: var(--bg-alt);
font-weight: bold;
text-align: left;
}
tr:hover {
background: #f2f2f2;
}
/* === FORMS === */
form {
display: flex;
flex-direction: column;
gap: 1.4rem;
}
.box:has(> form) {
padding: 35px 35px;
}
fieldset {
border: 2px solid var(--border);
border-radius: 0.8em;
padding: 1.2rem 1.5rem;
background: var(--bg-alt);
}
legend {
font-weight: bold;
color: #000;
padding: 0 0.4rem;
font-size: 1.05rem;
}
label {
font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
width: 100%;
font-size: 1rem;
margin-top: 6px;
margin-bottom: 8px;
border: 2px solid var(--border);
border-radius: 0.5em;
padding: 0.4rem 0.5rem;
transition: all 0.2s ease;
background: var(--bg);
}
textarea {
resize: vertical;
min-height: 100px;
}
input:focus,
textarea:focus,
select:focus {
outline: none;
border-color: #000;
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
background: #f9f9f9;
}
input[type="radio"],
input[type="checkbox"] {
accent-color: #000;
transform: scale(1.2);
margin-right: 0.3rem;
}
/* === BUTTONS === */
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
padding: 10px 20px;
border: 2px solid var(--border);
border-radius: 0.5em;
font-weight: bold;
font-size: 1rem;
background: linear-gradient(180deg, #fff 0%, #f2f2f2 100%);
cursor: pointer;
transition: all 0.2s ease;
align-self: flex-start;
}
button {
width: 100%;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
background: #eaeaea;
box-shadow: rgba(0, 0, 0, 0.25) 3px 3px 6px;
transform: translateY(-2px);
}
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
transform: translateY(0);
box-shadow: rgba(0, 0, 0, 0.15) 1px 1px 3px;
background: #f7f7f7;
}
/* === HR, CODE, ETC. === */
hr {
border: 0;
border-top: 2px solid var(--border);
margin: 1.5rem 0;
}
img {
max-width: 100%;
border-radius: 0.5em;
}
code, pre {
background: #f4f4f4;
border: 1px solid #ccc;
border-radius: 0.4em;
padding: 0.3em 0.5em;
font-family: "Courier New", monospace;
}
pre {
padding: 1em;
overflow-x: auto;
}
/* === RESPONSIVE === */
@media (max-width: 900px) {
header, .box {
width: 95%;
padding: 20px;
}
button {
width: 100%;
}
textarea {
width: 100%;
}
}
@media (max-width: 600px) {
header h1 {
font-size: 1.7rem;
}
header h2 {
font-size: 0.95rem;
}
}

View File

@@ -0,0 +1,41 @@
<?php
?>
<!doctype html>
<html lang="pl">
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<meta charset="UTF-8">
<title>Z40 - Jagoda</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Zadanie Z40</h1>
<h2>Autor: Jakub Grzegorczyk</h2>
</header>
<div class="box">
<p>Napisz program, który dla stałej haslo=Jagoda sprawdza czy wprowadzony z klawiatury ciąg znaków jest zgodny z hasłem.</p>
</div>
<div class="box">
<form action="index.php" method="post">
<fieldset>
<label for="haslo">Podaj hasło:</label>
<input type="password" name="haslo" id="haslo" required>
</fieldset>
<button type="submit">Wyślij</button>
</form>
</div>
<?php
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$haslo = htmlspecialchars($_POST['haslo']);
echo '<div class="box">';
if ($haslo == 'Jagoda') {
echo "Hasło jest prawidłowe";
} else {
echo "Hasło <i>{$haslo}</i> jest błędne";
}
}
?>
</body>
</html>

View File

@@ -0,0 +1,299 @@
/* === UNIVERSAL SCHOOL TEMPLATE CSS (BLACK & WHITE EDITION) === */
/* clean, modern, and copy-paste friendly for all projects */
/* === RESET === */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
/* === VARIABLES === */
:root {
--accent: #000;
--border: #000;
--bg: #fff;
--bg-alt: #f7f7f7;
--text: #111;
--shadow: rgba(0, 0, 0, 0.15) 3px 3px 6px;
--radius: 1em;
--max-width: 1300px;
}
/* === PAGE === */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Verdana, sans-serif;
background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
color: var(--text);
display: flex;
flex-direction: column;
align-items: center;
min-height: 100vh;
line-height: 1.6;
}
/* === HEADER === */
header {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 20px 30px;
box-shadow: var(--shadow);
background: var(--bg);
width: 95%;
max-width: var(--max-width);
text-align: center;
margin-top: 25px;
transition: box-shadow 0.3s ease, transform 0.2s ease;
}
header:hover {
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
transform: translateY(-2px);
}
header h1 {
font-size: 2.2rem;
}
header h2 {
margin-top: 0.5rem;
font-weight: 400;
font-size: 1.1rem;
color: #444;
}
/* === BOX === */
.box {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 25px 35px;
margin-top: 25px;
background: var(--bg);
box-shadow: var(--shadow);
width: 95%;
max-width: var(--max-width);
transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.box:hover {
transform: translateY(-2px);
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
}
/* === TEXT ELEMENTS === */
p {
margin-bottom: 1rem;
}
.box > p:last-child {
margin-bottom: 0;
}
h1, h2, h3, h4 {
margin-bottom: 0.5rem;
font-weight: 600;
}
a {
color: #000;
text-decoration: underline;
font-weight: 500;
}
a:hover {
opacity: 0.7;
}
/* === LISTS === */
ul, ol {
margin: 1rem 0 1rem 1.5rem;
}
li {
margin-bottom: 0.4rem;
}
/* === TABLES === */
table {
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
background: var(--bg);
border: 2px solid var(--border);
border-radius: 0.6em;
overflow: hidden;
box-shadow: var(--shadow);
}
th, td {
padding: 10px 12px;
border-bottom: 1px solid #ccc;
}
th {
background: var(--bg-alt);
font-weight: bold;
text-align: left;
}
tr:hover {
background: #f2f2f2;
}
/* === FORMS === */
form {
display: flex;
flex-direction: column;
gap: 1.4rem;
}
.box:has(> form) {
padding: 35px 35px;
}
fieldset {
border: 2px solid var(--border);
border-radius: 0.8em;
padding: 1.2rem 1.5rem;
background: var(--bg-alt);
}
legend {
font-weight: bold;
color: #000;
padding: 0 0.4rem;
font-size: 1.05rem;
}
label {
font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
width: 100%;
font-size: 1rem;
margin-top: 6px;
margin-bottom: 8px;
border: 2px solid var(--border);
border-radius: 0.5em;
padding: 0.4rem 0.5rem;
transition: all 0.2s ease;
background: var(--bg);
}
textarea {
resize: vertical;
min-height: 100px;
}
input:focus,
textarea:focus,
select:focus {
outline: none;
border-color: #000;
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
background: #f9f9f9;
}
input[type="radio"],
input[type="checkbox"] {
accent-color: #000;
transform: scale(1.2);
margin-right: 0.3rem;
}
/* === BUTTONS === */
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
padding: 10px 20px;
border: 2px solid var(--border);
border-radius: 0.5em;
font-weight: bold;
font-size: 1rem;
background: linear-gradient(180deg, #fff 0%, #f2f2f2 100%);
cursor: pointer;
transition: all 0.2s ease;
align-self: flex-start;
}
button {
width: 100%;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
background: #eaeaea;
box-shadow: rgba(0, 0, 0, 0.25) 3px 3px 6px;
transform: translateY(-2px);
}
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
transform: translateY(0);
box-shadow: rgba(0, 0, 0, 0.15) 1px 1px 3px;
background: #f7f7f7;
}
/* === HR, CODE, ETC. === */
hr {
border: 0;
border-top: 2px solid var(--border);
margin: 1.5rem 0;
}
img {
max-width: 100%;
border-radius: 0.5em;
}
code, pre {
background: #f4f4f4;
border: 1px solid #ccc;
border-radius: 0.4em;
padding: 0.3em 0.5em;
font-family: "Courier New", monospace;
}
pre {
padding: 1em;
overflow-x: auto;
}
/* === RESPONSIVE === */
@media (max-width: 900px) {
header, .box {
width: 95%;
padding: 20px;
}
button {
width: 100%;
}
textarea {
width: 100%;
}
}
@media (max-width: 600px) {
header h1 {
font-size: 1.7rem;
}
header h2 {
font-size: 0.95rem;
}
}

View File

@@ -0,0 +1,79 @@
<?php
?>
<!doctype html>
<html lang="pl">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Z42 - Całkowite parzyste</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Zadanie Z42</h1>
<h2>Autor: Jakub Grzegorczyk</h2>
</header>
<div class="box">
<p>
Dane są dwie różne liczby całkowite.<br>
Napisz program który:<br>
sprawdza czy podane dwie liczby całkowite są parzyste i tylko w tym przypadku wypisuje większą z nich. W przypadku podania liczby nieparzystej wypisuje która to liczba lub liczby.<br>
Wejście<br>
Na wejściu dwie różne liczby całkowite.<br>
Wyjście<br>
Na wyjściu większa z nich jeśli obie są parzyste lub ta liczba lub liczby jeśli są nieparzyste.<br>
Przykład 1<br>
4 8<br>
8<br>
Przykład 2<br>
3 4<br>
3<br>
Przykład 3<br>
1 7<br>
1<br>
7<br>
</p>
</div>
<div class="box">
<form action="index.php" method="post">
<fieldset>
<label for="a">Podaj liczbę A:</label>
<input type="number" name="a" id="a" required>
<label for="b">Podaj liczbę B:</label>
<input type="number" name="b" id="b" required>
</fieldset>
<button type="submit">Wyślij</button>
</form>
</div>
<?php
if($_SERVER['REQUEST_METHOD'] == 'POST') {
$a = htmlspecialchars($_POST['a']);
$b = htmlspecialchars($_POST['b']);
echo "<div class='box'>";
echo "A = {$a}<br>";
echo "B = {$b}<br>";
if($a % 2 == 0 && $b % 2 == 0) {
if ($a > $b) {
echo "Większa jest liczba a = {$a}<br>";
} elseif ($a < $b) {
echo "Większa jest liczba b = {$b}<br>";
} else {
echo "Liczby są równe";
}
} else {
if ($a % 2 != 0 && $b % 2 != 0){
echo "Liczby a = {$a} i b = {$b} są nieparzyste";
} elseif ($a % 2 != 0) {
echo "Liczba a = {$a} jest nieparzysta";
} elseif ($b % 2 != 0) {
echo "Liczba b = {$b} jest nieparzysta";
}
}
echo "</div>";
}
?>
</body>
</html>

View File

@@ -0,0 +1,299 @@
/* === UNIVERSAL SCHOOL TEMPLATE CSS (BLACK & WHITE EDITION) === */
/* clean, modern, and copy-paste friendly for all projects */
/* === RESET === */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
/* === VARIABLES === */
:root {
--accent: #000;
--border: #000;
--bg: #fff;
--bg-alt: #f7f7f7;
--text: #111;
--shadow: rgba(0, 0, 0, 0.15) 3px 3px 6px;
--radius: 1em;
--max-width: 1300px;
}
/* === PAGE === */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Verdana, sans-serif;
background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
color: var(--text);
display: flex;
flex-direction: column;
align-items: center;
min-height: 100vh;
line-height: 1.6;
}
/* === HEADER === */
header {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 20px 30px;
box-shadow: var(--shadow);
background: var(--bg);
width: 95%;
max-width: var(--max-width);
text-align: center;
margin-top: 25px;
transition: box-shadow 0.3s ease, transform 0.2s ease;
}
header:hover {
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
transform: translateY(-2px);
}
header h1 {
font-size: 2.2rem;
}
header h2 {
margin-top: 0.5rem;
font-weight: 400;
font-size: 1.1rem;
color: #444;
}
/* === BOX === */
.box {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 25px 35px;
margin-top: 25px;
background: var(--bg);
box-shadow: var(--shadow);
width: 95%;
max-width: var(--max-width);
transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.box:hover {
transform: translateY(-2px);
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
}
/* === TEXT ELEMENTS === */
p {
margin-bottom: 1rem;
}
.box > p:last-child {
margin-bottom: 0;
}
h1, h2, h3, h4 {
margin-bottom: 0.5rem;
font-weight: 600;
}
a {
color: #000;
text-decoration: underline;
font-weight: 500;
}
a:hover {
opacity: 0.7;
}
/* === LISTS === */
ul, ol {
margin: 1rem 0 1rem 1.5rem;
}
li {
margin-bottom: 0.4rem;
}
/* === TABLES === */
table {
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
background: var(--bg);
border: 2px solid var(--border);
border-radius: 0.6em;
overflow: hidden;
box-shadow: var(--shadow);
}
th, td {
padding: 10px 12px;
border-bottom: 1px solid #ccc;
}
th {
background: var(--bg-alt);
font-weight: bold;
text-align: left;
}
tr:hover {
background: #f2f2f2;
}
/* === FORMS === */
form {
display: flex;
flex-direction: column;
gap: 1.4rem;
}
.box:has(> form) {
padding: 35px 35px;
}
fieldset {
border: 2px solid var(--border);
border-radius: 0.8em;
padding: 1.2rem 1.5rem;
background: var(--bg-alt);
}
legend {
font-weight: bold;
color: #000;
padding: 0 0.4rem;
font-size: 1.05rem;
}
label {
font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
width: 100%;
font-size: 1rem;
margin-top: 6px;
margin-bottom: 8px;
border: 2px solid var(--border);
border-radius: 0.5em;
padding: 0.4rem 0.5rem;
transition: all 0.2s ease;
background: var(--bg);
}
textarea {
resize: vertical;
min-height: 100px;
}
input:focus,
textarea:focus,
select:focus {
outline: none;
border-color: #000;
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
background: #f9f9f9;
}
input[type="radio"],
input[type="checkbox"] {
accent-color: #000;
transform: scale(1.2);
margin-right: 0.3rem;
}
/* === BUTTONS === */
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
padding: 10px 20px;
border: 2px solid var(--border);
border-radius: 0.5em;
font-weight: bold;
font-size: 1rem;
background: linear-gradient(180deg, #fff 0%, #f2f2f2 100%);
cursor: pointer;
transition: all 0.2s ease;
align-self: flex-start;
}
button {
width: 100%;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
background: #eaeaea;
box-shadow: rgba(0, 0, 0, 0.25) 3px 3px 6px;
transform: translateY(-2px);
}
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
transform: translateY(0);
box-shadow: rgba(0, 0, 0, 0.15) 1px 1px 3px;
background: #f7f7f7;
}
/* === HR, CODE, ETC. === */
hr {
border: 0;
border-top: 2px solid var(--border);
margin: 1.5rem 0;
}
img {
max-width: 100%;
border-radius: 0.5em;
}
code, pre {
background: #f4f4f4;
border: 1px solid #ccc;
border-radius: 0.4em;
padding: 0.3em 0.5em;
font-family: "Courier New", monospace;
}
pre {
padding: 1em;
overflow-x: auto;
}
/* === RESPONSIVE === */
@media (max-width: 900px) {
header, .box {
width: 95%;
padding: 20px;
}
button {
width: 100%;
}
textarea {
width: 100%;
}
}
@media (max-width: 600px) {
header h1 {
font-size: 1.7rem;
}
header h2 {
font-size: 0.95rem;
}
}

View File

@@ -0,0 +1,22 @@
<?php
?>
<!doctype html>
<html lang="pl">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Z43 - Liczba dwucyfrowa</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Zadanie Z43</h1>
<h2>Autor: Jakub Grzegorczyk</h2>
</header>
<div class="box">
<p></p>
</div>
</body>
</html>

View File

@@ -0,0 +1,299 @@
/* === UNIVERSAL SCHOOL TEMPLATE CSS (BLACK & WHITE EDITION) === */
/* clean, modern, and copy-paste friendly for all projects */
/* === RESET === */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
/* === VARIABLES === */
:root {
--accent: #000;
--border: #000;
--bg: #fff;
--bg-alt: #f7f7f7;
--text: #111;
--shadow: rgba(0, 0, 0, 0.15) 3px 3px 6px;
--radius: 1em;
--max-width: 1300px;
}
/* === PAGE === */
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Verdana, sans-serif;
background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
color: var(--text);
display: flex;
flex-direction: column;
align-items: center;
min-height: 100vh;
line-height: 1.6;
}
/* === HEADER === */
header {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 20px 30px;
box-shadow: var(--shadow);
background: var(--bg);
width: 95%;
max-width: var(--max-width);
text-align: center;
margin-top: 25px;
transition: box-shadow 0.3s ease, transform 0.2s ease;
}
header:hover {
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
transform: translateY(-2px);
}
header h1 {
font-size: 2.2rem;
}
header h2 {
margin-top: 0.5rem;
font-weight: 400;
font-size: 1.1rem;
color: #444;
}
/* === BOX === */
.box {
border: 2px solid var(--border);
border-radius: var(--radius);
padding: 25px 35px;
margin-top: 25px;
background: var(--bg);
box-shadow: var(--shadow);
width: 95%;
max-width: var(--max-width);
transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.box:hover {
transform: translateY(-2px);
box-shadow: rgba(0, 0, 0, 0.25) 4px 4px 10px;
}
/* === TEXT ELEMENTS === */
p {
margin-bottom: 1rem;
}
.box > p:last-child {
margin-bottom: 0;
}
h1, h2, h3, h4 {
margin-bottom: 0.5rem;
font-weight: 600;
}
a {
color: #000;
text-decoration: underline;
font-weight: 500;
}
a:hover {
opacity: 0.7;
}
/* === LISTS === */
ul, ol {
margin: 1rem 0 1rem 1.5rem;
}
li {
margin-bottom: 0.4rem;
}
/* === TABLES === */
table {
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
background: var(--bg);
border: 2px solid var(--border);
border-radius: 0.6em;
overflow: hidden;
box-shadow: var(--shadow);
}
th, td {
padding: 10px 12px;
border-bottom: 1px solid #ccc;
}
th {
background: var(--bg-alt);
font-weight: bold;
text-align: left;
}
tr:hover {
background: #f2f2f2;
}
/* === FORMS === */
form {
display: flex;
flex-direction: column;
gap: 1.4rem;
}
.box:has(> form) {
padding: 35px 35px;
}
fieldset {
border: 2px solid var(--border);
border-radius: 0.8em;
padding: 1.2rem 1.5rem;
background: var(--bg-alt);
}
legend {
font-weight: bold;
color: #000;
padding: 0 0.4rem;
font-size: 1.05rem;
}
label {
font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
width: 100%;
font-size: 1rem;
margin-top: 6px;
margin-bottom: 8px;
border: 2px solid var(--border);
border-radius: 0.5em;
padding: 0.4rem 0.5rem;
transition: all 0.2s ease;
background: var(--bg);
}
textarea {
resize: vertical;
min-height: 100px;
}
input:focus,
textarea:focus,
select:focus {
outline: none;
border-color: #000;
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
background: #f9f9f9;
}
input[type="radio"],
input[type="checkbox"] {
accent-color: #000;
transform: scale(1.2);
margin-right: 0.3rem;
}
/* === BUTTONS === */
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
padding: 10px 20px;
border: 2px solid var(--border);
border-radius: 0.5em;
font-weight: bold;
font-size: 1rem;
background: linear-gradient(180deg, #fff 0%, #f2f2f2 100%);
cursor: pointer;
transition: all 0.2s ease;
align-self: flex-start;
}
button {
width: 100%;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
background: #eaeaea;
box-shadow: rgba(0, 0, 0, 0.25) 3px 3px 6px;
transform: translateY(-2px);
}
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
transform: translateY(0);
box-shadow: rgba(0, 0, 0, 0.15) 1px 1px 3px;
background: #f7f7f7;
}
/* === HR, CODE, ETC. === */
hr {
border: 0;
border-top: 2px solid var(--border);
margin: 1.5rem 0;
}
img {
max-width: 100%;
border-radius: 0.5em;
}
code, pre {
background: #f4f4f4;
border: 1px solid #ccc;
border-radius: 0.4em;
padding: 0.3em 0.5em;
font-family: "Courier New", monospace;
}
pre {
padding: 1em;
overflow-x: auto;
}
/* === RESPONSIVE === */
@media (max-width: 900px) {
header, .box {
width: 95%;
padding: 20px;
}
button {
width: 100%;
}
textarea {
width: 100%;
}
}
@media (max-width: 600px) {
header h1 {
font-size: 1.7rem;
}
header h2 {
font-size: 0.95rem;
}
}