Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Aprende Mastering Integer Numbers in Python | Familiarizándonos con los Números en Python
Tipos de Datos en Python
course content

Contenido del Curso

Tipos de Datos en Python

Tipos de Datos en Python

1. Familiarizándonos con los Números en Python
2. ¿Verdadero o Falso?
3. Strings
4. Reuniendo Todos los Temas

book
Mastering Integer Numbers in Python

You might be accustomed to specifying numbers in ways such as:

  • 1,000,000 (with commas);
  • 1 000 000 (with spaces).

However, Python will not understand this. 😢

These formats are understandable for a person but not for a computer, so the right way is 1000000 without commas or spaces.

If you want to use separators for better readability, Python allows the following syntax:

Tarea

Swipe to start coding

A small company is planning its budget for the first two quarters of the year. However, some financial figures need to be formatted correctly.

Here are the allocated budgets:

  • Q1 budget allocation: q1_budget = 750,000.
  • Q2 budget allocation: q2_budget = 1 200 500.

Adjust these values so they are compatible and output them.

Solución

Switch to desktopCambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones
¿Todo estuvo claro?

¿Cómo podemos mejorarlo?

¡Gracias por tus comentarios!

Sección 1. Capítulo 3
toggle bottom row

book
Mastering Integer Numbers in Python

You might be accustomed to specifying numbers in ways such as:

  • 1,000,000 (with commas);
  • 1 000 000 (with spaces).

However, Python will not understand this. 😢

These formats are understandable for a person but not for a computer, so the right way is 1000000 without commas or spaces.

If you want to use separators for better readability, Python allows the following syntax:

Tarea

Swipe to start coding

A small company is planning its budget for the first two quarters of the year. However, some financial figures need to be formatted correctly.

Here are the allocated budgets:

  • Q1 budget allocation: q1_budget = 750,000.
  • Q2 budget allocation: q2_budget = 1 200 500.

Adjust these values so they are compatible and output them.

Solución

Switch to desktopCambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones
¿Todo estuvo claro?

¿Cómo podemos mejorarlo?

¡Gracias por tus comentarios!

Sección 1. Capítulo 3
Switch to desktopCambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones
We're sorry to hear that something went wrong. What happened?
some-alt