SELECT
t1.f1 AS t1_f1, t1.f2 AS t1_f2, /*...*/ t1.fn AS t1_fn
,null AS t2_f1, null AS t2_f2, /*...*/ null AS t2_fn
/*...*/
,null AS t7_f1, null AS t7_f2, /*...*/ null AS t7_fn
FROM table1 t1
UNION
SELECT
null AS t1_f1, null AS t1_f2, /*...*/ null AS t1_fn
t2.f1 AS t2_f1, t2.f2 AS t2_f2, /*...*/ t2.fn AS t2_fn
/*...*/
,null AS t7_f1, null AS t7_f2, /*...*/ null AS t7_fn
FROM table2 t2
UNION
/*...*/
SELECT
null AS t1_f1, null AS t1_f2, /*...*/ null AS t1_fn
,null AS t2_f1, null AS t2_f2, /*...*/ null AS t2_fn
/*...*/
,t7.f1 AS t7_f1, t7.f2 AS t7_f2, /*...*/ t7.fn AS t7_fn
FROM tablen t7
alpha = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z']
alpha_map = {c: str(i) for i, c in enumerate(alpha, 1)}
word = input()
new_word = ''.join(f'{idx} ' if idx else orig for idx, orig in ((alpha_map.get(c), c) for c in word))
print(new_word)
COUNT(*)
SELECT
case when id in (1,2,3,4) then 'Начальная школа'
when id in (5,6,7,8,9) then 'Средняя школа'
when id in (10,11) then 'Старшая школа'
end AS Class_type,
(
SELECT COUNT(*)
FROM class cc
WHERE (
case when сс.id in (1,2,3,4,5) then 'Начальная школа'
when cc.id in (6,7,8,9) then 'Средняя школа'
when cc.id in (10,11) then 'Старшая школа'
) = (
case when c.id in (1,2,3,4) then 'Начальная школа'
when c.id in (5,6,7,8,9) then 'Средняя школа'
when c.id in (10,11) then 'Старшая школа'
)
),
SUM(case when s.ocenka>4 then 1 end) AS 'Отличники'
FROM class c
GROUP BY Class_type
from PIL import Image
q = input("Название картинки: ")
img = Image.open(q)
img = img.convert("RGB")
(w,h) = img.size
print(w*h)
with open("img.txt","w") as file:
for y in range(h):
for x in range(w):
r, g, b = img.getpixel((x,y))
file.write("#" if (r, g, b) == (0, 0, 0) else "_")
file.write("\n")
print(img.getpixel((0,0)))
input("Enter что-бы завершить: ")
SELECT price
FROM Laptop
LIMIT 1
SELECT min(price)
FROM Laptop
SELECT DISTINCT model, price
FROM PC p
JOIN Laptop l ON l.price = p.price
SELECT DISTINCT p.model, p.price, l.model
FROM PC p
JOIN Laptop l ON l.price = p.price
server {
listen tg.my_own_domain.net:8079;
server_name tg.my_own_domain.net;
access_log /var/log/nginx/tg.my_own_domain.net-access.log;
error_log /var/log/nginx/tg.my_own_domain.net-error.log;
location / {
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Server $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass https://api.telegram.org/;
client_max_body_size 100M;
}
}
n = h
n.remove(n[j])
if h[j] not in n:
print(h[j])
n = h[:]
current_date >= start_date and current_date <= end_date
start_date <= current_date <= end_date
-r
.