Python Mini Project String, Integer, Float and Concatenate Mini Project

Publicado el: 23 julio 2023
en el canal de: DevOpsUsman
21
0

This project for beginners and it give brief introduction of string, integer, float and concatenation.
#python #pythonprogramming #miniproject #coding #beginners
Difference between string, Integer and Float.
String:
A string is sequence of characters enclosed in
single or double "" qoutes.
It represents the textual data and can contain
letters, numbers, symbols or any combination
of these in double qoutes.
for example: "Hello World" , "Hello John",
"123 Hello Mic Testing".

Integers:
An Integer is whole number without any fractional
portion.
It can be positive or negative.
For Example:
0, 100, -300, -980, 1090, 14000 are
all integers.
Note: Zero is also integer.

Float:
A float is a numerical value that contains
a decimal portion.
It represents real numbers and can used to store
both whole numbers and fractions.
For Example:
3.14, 40.00, 56.89 are all floats.
Code is below.

#How to use str, int and float and concatenate the results.

your_name = str(input("What is your name? "))

birth_year = int(input("What is your birth year? "))

school_percenatage = float(input("What is your school percentage? "))

#Now make function to concatenate the result.

userdata = f"My name is {your_name}, my birth year is {birth_year} and my school percentage is {school_percenatage}%"

print(userdata)

#Now run the function and check it.


En esta página del sitio puede ver el video en línea Python Mini Project String, Integer, Float and Concatenate Mini Project de Duración hora minuto segunda en buena calidad , que subió el usuario DevOpsUsman 23 julio 2023, comparta el enlace con amigos y conocidos, en youtube este video ya ha sido visto 21 veces y le gustó 0 a los espectadores. Disfruta viendo!