modified: content/posts/informatics/ms-word.mdx

modified:   content/posts/informatics/python-task.mdx
	modified:   content/posts/informatics/python-well.mdx
main
joker 2 years ago
parent 7fa741f192
commit 93c6b638d7
  1. 15
      content/posts/informatics/python-task.mdx
  2. 2
      content/posts/informatics/python-well.mdx

@ -23,3 +23,18 @@ tags:
* (9) после увеличения (1,0)
## Залача 2
На вход дается целочисленный массив nums, переместите все 0 в его конец, сохраняя относительный порядок ненулевых элементов.
Обратите внимание, что вы должны сделать это на месте, не копируя массив.
Example 1:
Input: nums = [0,1,0,3,12]
Output: [1,3,12,0,0]
Example 2:
Input: nums = [0]
Output: [0]

@ -111,7 +111,7 @@ tags:
print(S[-2]) # Второй элемент с конца в S
# a
print(S[len(S)-l]) # Отрицательная индексация, сложный путь
print(S[len(S)-1]) # Отрицательная индексация, сложный путь
# m
print(S[1:3]) # Срез S со смещения 1 до 2 (не 3)
# 'pa'

Loading…
Cancel
Save