fork download
  1. # your code goes here
  2.  
  3. import re
  4.  
  5. a = "%I'm a sentence.|"
  6. b = re.sub(r"%(.*?)\|", r"<\1>", a)
  7. print(b)
Success #stdin #stdout 0.02s 27720KB
stdin
Standard input is empty
stdout
<I'm a sentence.>