Files
python-labs/TEMA1/report1.txt
2025-09-15 10:21:54 +03:00

113 строки
4.6 KiB
Plaintext
Исходник Ответственный История

Этот файл содержит невидимые символы Юникода
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Отчёт по теме 1. Знакомство с интерпретатором и интерактивной оболочкой IDLE
Таболин Иван Андреевич А-01-23
1. Создал свою папку на диске, а в ней создал папки TEMAn
2. Запустил на выполнение программу-интерпретатор, выбрав ее ярлык «Python 3.13».
3. 3.Изучил содержание открывающегося диалогового окна интерпретатора. Вывел "hello".
```
>>> print('Hello')
Hello
```
4. Запросил от пользователя имя и ввёл с клавиатуры.
```
>>> h=input('Your name=')
Your name=Ivan
```
5. Завершил работу интерпретатора.
```
>>> exit()
```
6. Запустил интерактивную графическую оболочку IDLE среды Python.
7. Изучил устройство главного командного окна среды.
8. Настроил рабочий каталог среды
```
import os
os.chdir('C:\MPEI\POAS\Tabolin\Tema1\python-labs\TEMA1')
```
9. Изучил предложения главного меню и настроил интерфейс оболочки IDLE.
10. Создал файл программы и сохранил под именем Pr0.py.
--------Pr0.py--------
#Программа по Теме 1 Таболин Иван Андреевич
print('Hello')
h=input('Your name=')
import os
os.chdir('C:\MPEI\POAS\Tabolin\Tema1\python-labs\TEMA1')
----------------------
Запустил программу на выполнение разными способами.
```
import Pr0
Hello
Your name=Ivan
```
11. Запустил на выполнение Prb1.py
```
import prb1
Как Вас зовут? Ivan
Привет, Ivan
```
12.
Содержание файла Pr0.cpython-34.pyc:
у
;Dµh° г  уP • \ " S 5 \" S5 rSSKr\R " S5 g)ЪHelloz
Your name=й NzC:\MPEI\POAS\Tabolin\Tema1\)ЪprintЪinputЪosЪchdir© у Ъ!C:\MPEI\POAS\Tabolin\Tema1\Pr0.pyЪ<module>r  s& рб Ђg„Щ УЂЫ Ш Р +Х ,r
В папке __pycache__ содержится скомпилированный двоичный код, который нужен для оптимизации
13. Создал файл протокола темы.
14. Изучил раздел "Help"
```
help(print)
Help on built-in function print in module builtins:
print(*args, sep=' ', end='\n', file=None, flush=False)
Prints the values to a stream, or to sys.stdout by default.
sep
string inserted between values, default a space.
end
string appended after the last value, default a newline.
file
a file-like object (stream); defaults to the current sys.stdout.
flush
whether to forcibly flush the stream.
help(print),help(input)
Help on built-in function print in module builtins:
print(*args, sep=' ', end='\n', file=None, flush=False)
Prints the values to a stream, or to sys.stdout by default.
sep
string inserted between values, default a space.
end
string appended after the last value, default a newline.
file
a file-like object (stream); defaults to the current sys.stdout.
flush
whether to forcibly flush the stream.
Help on built-in function input in module builtins:
input(prompt='', /)
Read a string from standard input. The trailing newline is stripped.
The prompt string, if given, is printed to standard output without a
trailing newline before reading input.
If the user hits EOF (*nix: Ctrl-D, Windows: Ctrl-Z+Return), raise EOFError.
On *nix systems, readline is used if available.
(None, None)
```
15.
Открыл файл prb1.py в текстовом редакторе среды.
С помощью предложения "Window" переключался между окнами.
Запустил программу prb1.py на выполнение с помощью предложения "Run".
```
============================ RESTART: C:\MPEI\POAS\Tabolin\Tema1\prb1.py ===========================
Как Вас зовут? Ivan
Привет, Ivan
```
Открыл файл Pr0.py в текстовом редакторе среды и переключал окна.
Закрыл два окна текстового редактора с помощью предложения "Close window".