ulvis.paste.net

Paste Search Dynamic
Recent pastes
License
  1. # your code goes here
  2. import re
  3. text = 'cookie=a5243217ddaf838f9dd08bc47a77ed85 expires on 12/2020 License     -1990035336801296152 MachineID   -8833698968034103702 a5243217ddaf838f9dd08bc47a77ed85 -1990035336801296152 -8833698968034103702 CoGB 1024MB'
  4.  
  5. cookie_pattern = re.compile('cookie=(.*?)')
  6. m = cookie_pattern.match(text)
  7. print m.groups()
  8.  
  9. patterns = (r'(License)', r'(MachineID)')
  10. for p in patterns:
  11.         text = re.sub(p, r'\n\1', text)
Parsed in 0.005 seconds