ответвлено от main/python-labs
report:добавлен
Этот коммит содержится в:
13
TEMA4/r.s
Обычный файл
13
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))
|
||||||
@@ -20,9 +20,9 @@ import cmath, math, random, time
|
|||||||
### Решение
|
### Решение
|
||||||
```
|
```
|
||||||
#1
|
#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)
|
print(res)
|
||||||
(8, 2)
|
(8.0, 2.6000000000000014)
|
||||||
#2
|
#2
|
||||||
Msk = time.localtime()
|
Msk = time.localtime()
|
||||||
print(Msk)
|
print(Msk)
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import cmath, math, random, time
|
import cmath, math, random, time
|
||||||
|
|
||||||
# 1.
|
# 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)
|
print(res)
|
||||||
|
|
||||||
# 2.
|
# 2.
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user