From 7a2bc89a244a2493b74d9e275436056b494fdc41 Mon Sep 17 00:00:00 2001 From: Danil Date: Fri, 24 Oct 2025 12:02:39 +0300 Subject: [PATCH] =?UTF-8?q?report:=D0=B4=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- TEMA4/r.s | 13 +++++++++++++ TEMA4/task.md | 4 ++-- TEMA4/task.py | 2 +- 3 files changed, 16 insertions(+), 3 deletions(-) create mode 100644 TEMA4/r.s diff --git a/TEMA4/r.s b/TEMA4/r.s new file mode 100644 index 0000000..568131f --- /dev/null +++ b/TEMA4/r.s @@ -0,0 +1,13 @@ +import random +print('Без использования функции seed') +for i in range(3): + print(random.randint(1,10)) +for i in range(3): + print(random.randint(1,10)) +print('seed = 4') +random.seed(4) +for i in range(3): + print(random.randint(1,10)) +random.seed(4) +for i in range(3): + print(random.randint(1,10)) diff --git a/TEMA4/task.md b/TEMA4/task.md index 9209b68..3a2976e 100644 --- a/TEMA4/task.md +++ b/TEMA4/task.md @@ -20,9 +20,9 @@ import cmath, math, random, time ### Решение ``` #1 -res = divmod(math.floor(round(cmath.phase(0.2+0.8j), 2) * 20), 3) +res = divmod((round(cmath.phase(0.2+0.8j), 2) * 20), 3) print(res) -(8, 2) +(8.0, 2.6000000000000014) #2 Msk = time.localtime() print(Msk) diff --git a/TEMA4/task.py b/TEMA4/task.py index 0fbdd31..99fe30d 100644 --- a/TEMA4/task.py +++ b/TEMA4/task.py @@ -1,7 +1,7 @@ import cmath, math, random, time # 1. -res = divmod(math.floor(round(cmath.phase(0.2+0.8j), 2) * 20), 3) +res = divmod((round(cmath.phase(0.2+0.8j), 2) * 20), 3) print(res) # 2.