Post

@PythonPr Answer: (A) "abcdefdef"
This problem demonstrates string manipulation in Python.
Explanation
String Repetition: In Python, the multiplication operator (*) used with a string and an integer repeats the string that many times. So, s2 * 2 evaluates to "defdef" [1.1].
English

@PythonPr A) is my answer.
The 3rd line code, result= s1+ s2*2 is to use the + operator to concatenate strings s1 and s2 *2. When s2 *2, the string "def" will be doubled and produce a new string "defdef".
Since s1 comes first in the formula of result, print (result) is “abcdefdef”.
English

@PythonPr A 2 strings would just add out as it is and muliply the 2 thats close to that string
English

@PythonPr A. Def (s2) make it double (*2) then combine it with abc (s1)
English

@PythonPr 6. Because of order of operations.
How did I do? 😊
English

























