Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Lære Naming Rules | Variables
Introduction to Python | Mobile-Friendly
course content

Kursinnhold

Introduction to Python | Mobile-Friendly

Introduction to Python | Mobile-Friendly

1. Python Basics
2. Variables
3. Strings

book
Naming Rules

There are several rules for naming variables in Python. These are the following:

  • A variable name must start with a letter or the underscore character, which means a variable name can not begin with a number.

  • A variable name may contain only English letters, numbers, and underscore characters.

  • Variables’ names are case sensitive, i.e., Chapter , chapter , and CHAPTER will be considered three different objects by Python.

question mark

Choose all the acceptable names for variables.

Select the correct answer

Alt var klart?

Hvordan kan vi forbedre det?

Takk for tilbakemeldingene dine!

Seksjon 2. Kapittel 2

Spør AI

expand
ChatGPT

Spør om hva du vil, eller prøv ett av de foreslåtte spørsmålene for å starte chatten vår

course content

Kursinnhold

Introduction to Python | Mobile-Friendly

Introduction to Python | Mobile-Friendly

1. Python Basics
2. Variables
3. Strings

book
Naming Rules

There are several rules for naming variables in Python. These are the following:

  • A variable name must start with a letter or the underscore character, which means a variable name can not begin with a number.

  • A variable name may contain only English letters, numbers, and underscore characters.

  • Variables’ names are case sensitive, i.e., Chapter , chapter , and CHAPTER will be considered three different objects by Python.

question mark

Choose all the acceptable names for variables.

Select the correct answer

Alt var klart?

Hvordan kan vi forbedre det?

Takk for tilbakemeldingene dine!

Seksjon 2. Kapittel 2
Vi beklager at noe gikk galt. Hva skjedde?
some-alt