Regular Expressions in Python | Match your desired pattern using Regex

preview_player
Показать описание
To see regex uses in a data Frame watch this video:

In this video we demonstrated how to pull out data from a text file using regex. we showed basic necessary things that are required to get started with regex.
Рекомендации по теме
Комментарии
Автор

Can you please help me with this
I want to parse a .blk file
section ABC
{
...
}
end ABC
Section XYZ
John
{
MN 0
PQ 2:1
}
Kev
{
OP 0
VW 2:1 description { !@, #$
}`
```

My target is to parse this file in such a way that if section is XYZ, I can get an array for John with dimensions 2x2 and fields [MN 1, PQ 2] and same for second array for Kev. It would be great if I can get help on this

priyansi