Percentage symbol


#1

Hello!!! I'm Esteban from Colombia and I'm wondering, what percentage symbol (%) is used for?

Thanks all for your answers :smile:


#2

It's called a modulus/modulo good that term and you ill be enlightened,


#3

Thank you Zeziba for your post. Is this symbol used in another way?


#4

It can be used for different things in different languages, in python it is generally used for string formatting and remainder division.

Example:

# String Formatting
a_string = 'string'
print("%s is the variable a_string" % a_string)
# Math
10 % 3
# OUTPUT: 1

#5

Thank you very much!!!!

:beers: