Скрипт для вычисления PPI на Python
Сам скрипт:
import math
width = input("Write Width: ")
height = input("Write Height: ")
inch = input("Write Inch: ").replace(',', '.')
ppi = math.sqrt((int(width) ** 2)+(int(height) ** 2))/float(inch);
ppi = round(ppi)
print(f'PPI: {ppi}')
12 комментариев