Skip to main content
2 of 2
added 16 characters in body
Gymhgy
  • 8k
  • 11
  • 35

C# (Visual C# Interactive Compiler), 73 bytes

a=>b=>{int i=0;return a.Select(x=>x>45&&b.Contains(++i)?(char)(x^40):x);}

Try it online!

Gymhgy
  • 8k
  • 11
  • 35