Daily Python Puzzle: String Concatenation

What is the output of this code snippet?

 

print(3 * 'un' + 'ium')

 

Python has powerful built-in capabilities for string manipulation.
Web companies like Google love Python because it is a perfect fit for the text-based World Wide Web.
The puzzle introduces two basic string manipulation operators.
The ‘+’ operator concatenates two strings. The ‘*’ operator concatenates a string to itself repeatedly. The standard arithmetic rules apply to these operators: multiplication first, then addition.
As a Python professional, you will find yourself using these operators on a daily basis.

 


Are you a master coder?
Test your skills now!

 

Related Video

Solution

unununium

 

Leave a Comment

Your email address will not be published. Required fields are marked *