Write the code for a Python function expand(x) that takes a list of strings, concatenates them, and returns the resulting string repeated three times. Input:…