Re: [Tutor] Query regarding Regular Expression

2017-06-28 Thread Alan Gauld via Tutor
On 28/06/17 21:27, cookiestar227 - Cookie Productions wrote: > So far have understood everything except for the following example: > t = "A fat cat doesn't eat oat but a rat eats bats." mo = re.findall("[force]at", t) > What I don't understand is the [force] part of the Regular Expr

[Tutor] Query regarding Regular Expression

2017-06-28 Thread cookiestar227 - Cookie Productions
I am using Python version 3.6.0 and am learning Python as my very first programming language. Right now I am studying Regular Expressions. We are finding all of the matched substrings in a string using the "findall" method with the following syntax: re.findall(pattern, string[, flags]) Here is