Computer Science, asked by redsoul7777777, 2 months ago

Predict the output of the following statement: print(“72”*2)

Answers

Answered by Oreki
0

\textsf{\large \textbf{Given Snippet}}

   \texttt{print("72" * 2)}

\textsf{\large \textbf{Explanation}}

   \text{In Python we can multiply sets of words, strings, or tuples.}\\\text{So, any str mutilped by a scalar like 1, 2, 3 etc will result in concatenation }\\\text{of the string \textit{n} times where \textit{n} is the number multiplied with.}\\\text{If the string is multiplied by a number less than or equal to 0, it returns an}\\\text{empty string.}

\textsf{\large \textbf{After Execution}}

   \texttt{7272}

Similar questions