firstarray = getsomething1()
secondarray = getsomething2()
getsomething3(firstarray, secondarray)
илиgetsomething3(getsomething1(), getsomething2())
sudo pip install -U grab
import re
p = re.compile(r"([\d\W]+)\n.*\[(.*)\].*\n.*", re.MULTILINE | re.UNICODE)
test_str = u"""00:00:05,233 --> 00:00:08,133
GAT[xd]fES: Amelia Earhart
is on one of the final legs
00:00:05,333 --> 00:00:08,433
[xd]fES: Amelia Earhart
is on one of the final legs
"""
subst = r"\1 \2"
result = re.sub(p, subst, test_str)
print result
ideone.com/K0zp7X