from os import system
from random import randint
i = 0
spisok = [randint(-100, 100) for i in range(6)]
print('Список до: ', spisok)
for i in range(len(spisok)):
if spisok[i] < 0:
spisok[i] = 'x'
else:
pass
print('Список после: ', spisok)
system('pause')
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
from os import system
from random import randint
i = 0
spisok = [randint(-100, 100) for i in range(6)]
print('Список до: ', spisok)
for i in range(len(spisok)):
if spisok[i] < 0:
spisok[i] = 'x'
else:
pass
print('Список после: ', spisok)
system('pause')