Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Comments | Comments
Python Tutorial for Beginners
course content

Зміст курсу

Python Tutorial for Beginners

Python Tutorial for Beginners

1. Introduction to Programming
2. Variables in Python
3. Comments
4. If...Else Statement

Comments

Comments are lines of text in your code that Python ignores because they are for people, not machines. In most cases, comments are created to explain a piece of code so that another programmer who will watch the code can understand it.

123
# This is a comment # Python ignores it print("Hello, kittens!")
copy

Comments begin with #, and after this you write the text you need. Let's take another example:

1234567
# Creating variables number_1 = 65 number_2 = 30 # Addition of two numbers sum_=number_1 + number_2 # Displaying the result on the screen print(sum_)
copy

In the code above, Python displays the message and ignores the comment.

Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів

Все було зрозуміло?

Секція 3. Розділ 1
toggle bottom row

Comments

Comments are lines of text in your code that Python ignores because they are for people, not machines. In most cases, comments are created to explain a piece of code so that another programmer who will watch the code can understand it.

123
# This is a comment # Python ignores it print("Hello, kittens!")
copy

Comments begin with #, and after this you write the text you need. Let's take another example:

1234567
# Creating variables number_1 = 65 number_2 = 30 # Addition of two numbers sum_=number_1 + number_2 # Displaying the result on the screen print(sum_)
copy

In the code above, Python displays the message and ignores the comment.

Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів

Все було зрозуміло?

Секція 3. Розділ 1
toggle bottom row

Comments

Comments are lines of text in your code that Python ignores because they are for people, not machines. In most cases, comments are created to explain a piece of code so that another programmer who will watch the code can understand it.

123
# This is a comment # Python ignores it print("Hello, kittens!")
copy

Comments begin with #, and after this you write the text you need. Let's take another example:

1234567
# Creating variables number_1 = 65 number_2 = 30 # Addition of two numbers sum_=number_1 + number_2 # Displaying the result on the screen print(sum_)
copy

In the code above, Python displays the message and ignores the comment.

Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів

Все було зрозуміло?

Comments are lines of text in your code that Python ignores because they are for people, not machines. In most cases, comments are created to explain a piece of code so that another programmer who will watch the code can understand it.

123
# This is a comment # Python ignores it print("Hello, kittens!")
copy

Comments begin with #, and after this you write the text you need. Let's take another example:

1234567
# Creating variables number_1 = 65 number_2 = 30 # Addition of two numbers sum_=number_1 + number_2 # Displaying the result on the screen print(sum_)
copy

In the code above, Python displays the message and ignores the comment.

Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Секція 3. Розділ 1
Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
We're sorry to hear that something went wrong. What happened?
some-alt