For Loop
We use loops if we want to repeat any action n-times.
1234prices = [100, 458, 231, 378] for i in prices: print(i, end = '')
12345# Decreasing prices by 1 prices = [3, 5, 6, 2, 7, 8] for i in prices: print(i, end = ' ')
end = ' '
means that the result will be written in one row (not column).
Все було зрозуміло?
Дякуємо за ваш відгук!
Секція 3. Розділ 7
Запитати АІ
Запитати АІ
Запитайте про що завгодно або спробуйте одне із запропонованих запитань, щоб почати наш чат
Suggested prompts:
Запитайте мені питання про цей предмет
Сумаризуйте цей розділ
Покажіть реальні приклади
Awesome!
Completion rate improved to 2.7
For Loop
Свайпніть щоб показати меню
We use loops if we want to repeat any action n-times.
1234prices = [100, 458, 231, 378] for i in prices: print(i, end = '')
12345# Decreasing prices by 1 prices = [3, 5, 6, 2, 7, 8] for i in prices: print(i, end = ' ')
end = ' '
means that the result will be written in one row (not column).
Все було зрозуміло?
Дякуємо за ваш відгук!
Секція 3. Розділ 7