diff --git a/script.py b/script.py new file mode 100644 index 0000000..76c1454 --- /dev/null +++ b/script.py @@ -0,0 +1,12 @@ +def main(): + with open('data.txt', 'r') as file: + data = file.readlines() + numbers = [int(line.strip()) for line in data if line.strip().isdigit()] + sorted_numbers = sorted(numbers) + + with open('output.txt', 'w') as outfile: + for number in sorted_numbers: + outfile.write(f"{number}\n") + +if __name__ == '__main__': + main() diff --git a/Скрины.docx b/Скрины.docx new file mode 100644 index 0000000..b0c5ae8 Binary files /dev/null and b/Скрины.docx differ