I have text file with several thousands lines. I want to parse this file into database and decided to write a regexp. Here's part of file:
blablabla checked=12 unchecked=1
blablabla unchecked=13
blablabla checked=14
As a result, I would like to get something like
(12,1)
(0,13)
(14,0)
Is it possible?
It's simplest to use two different regexes to pull the two numbers out: r" checked=(\d+)" and r" unchecked=(\d+)".
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With