Поделитесь своими знаниями, ответьте на вопрос:
Choose the most appropriate type of printer for these situations from the descriptions in B opposite. 1 a home user who wants to print text documents and family photographs 2 business people who need to print in large quantities at high quality in an office 3 engineers who want to make detailed line drawings4 professional typesetters in desktop publishing (e.g. to publish catalogues and magazines) 5 a company that wants to print carbon copies of bills and receiptsFind terms in B opposite which correspond to these definitions.1 a container that holds the ink in an ink-jet printer2 powdered ink used in laser printers3 small needles that press on the inked ribbon to make the characters on paper4 printer technology that produces text and pictures by hammering pins against a ribbon and the paper5 a language that tells a printer how to print a document6 a peripheral which combines a printer, a fax machine and photocopying and scanning capability into one device
Код написал на Python:
Рандомная строка из букв, цифр и знаков пунктуации:
import random
chars = "0123456789r!'#$%&()*+,-./:;<=>[email protected][\]^_`{|}~"
len_chars = len(chars)
str_result = ""
for i in range(10):
r_number = random.randint(0,len_chars)
str_result = str_result + chars[r_number]
print(str_result)
Проверка на цифры в строке (если будете считать как новую задачу, то знайте, кусок кода взял из первой для генерации случайной строки):
import random
chars = "0123456789r!'#$%&()*+,-./:;<=>[email protected][\]^_`{|}~"
len_chars = len(chars)
str_result = ""
for i in range(10):
r_number = random.randint(0,len_chars)
str_result = str_result + chars[r_number]
print(str_result)
counter = 0
for i in range(10):
if (i == 9):
if (str_result[i].isnumeric() == False):
print("There is no numbers in string")
else:
if (str_result[i].isnumeric() == True):
print("There is at least one number in string")
break
else:
continue