Submit solution
Points:
100.00 (partial)
Time limit:
1.5s
Memory limit:
512M
Input:
stdin
Output:
stdout
Problem type
Allowed languages
C++, Pascal, Python
Comments
code python nè from collections import deque f = open('vidu.inp','r') g = open('vidu.out','d') s = f.readline().strip() s1 = f.readline().strip() s = deque(s) for i in s1: if i == 'r': s.appendleft(s.pop()) else: s.append(s.popleft()) print(''.join(s), file=g) f.close g.close
strong text
Help me, pls give me a python or scratch code plsss
enter code here
????