I have tried a written a code like so re.findall(r'[A-Z]{3}[a-z][A-Z]{3}',string) to find the solution for this python challenge http://www.pythonchallenge.com/pc/def/equality.html it seems so hard to figure out. I'm getting 527 matches and none takes me to the next level. Help or close hints will be appreciated
silverdust
0
Newbie Poster
Recommended Answers
Jump to PostYou can perhaps add the condition that there is no uppercase letter before the first 3 ones or after the 3 last ones.
Jump to Postby having a capturing group ([a-z]), I still got 175 matches and they were just single letters
Did you place
[^A-Z]
as i told you?
Then it should look like this[^A-Z][A-Z]{3}([a-z])[A-Z]{3}[^A-Z]
All 8 Replies
Gribouillis
1,391
Programming Explorer
Team Colleague
silverdust
0
Newbie Poster
snippsat
661
Master Poster
silverdust
0
Newbie Poster
TrustyTony
888
pyMod
Team Colleague
Featured Poster
silverdust
0
Newbie Poster
snippsat
661
Master Poster
silverdust
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.