Python
2
Вклад в тег
dict1 = {1: "один", 2: "два"}
dict2 = dict1 # Так делать НЕЛЬЗЯ!
dict1 = {1: "один", 2: "два"}
dict2 = dict1.copy() # Так делать ПРАВИЛЬНО!
dict1 = {1: "один", 2: "два"}
dict2 = {}
for key in dict1:
dict2[key] = dict1[key]
dict1 = {1: "один", 2: "два"}
dict2 = {}
for key, item in dict1.items():
dict2[key] = item
dict1 = {1: "один", 2: "два"}
dict2 = {}
for keys in dict1:
dict2[keys] = dict1[keys] * 2
/headheight=0.5cm % Место для контитула
/headsep=0.5cm % Отступ для контитула
/usepackage [right=1cm, left=2.5cm, top=2cm, bottom=2cm]{geometry}
from PyQt5 import QtWidgets, QtCore
class WindowLayout(object):
def __init__(self):
button = QtWidgets.QWidget
self.verticalLayout = QtWidgets.QVBoxLayout(parent)
self.verticalLayout.addWidget(button, alignment=QtCore.Qt.AlignRight)