regex - Python - extract lines between multiple instances of the same delimiter -


i have file this

=== aa bb === aa cc dd == 11 

i need extract lines between "===" , put them in different variables (a list maybe).

can please me? thank you

with open('input.txt') input_file:     result = input_file.read().split('===\n') print result 

Comments

Popular posts from this blog

cakephp - simple blog with croogo -

How to group boxplot outliers in gnuplot -

bash - Performing variable substitution in a string -