Raj More
Raj More

Reputation: 48016

Next Capital letter using Regex Search

I use EditPlus.

This tool has a nice search option where you can search either regular text or RegEx search.

I want to search for the next Uppercase alphabet preceeded by a lowercase alphabet. What do I put in the search box for this?

Upvotes: 1

Views: 1118

Answers (2)

Christopher Pickslay
Christopher Pickslay

Reputation: 17762

[a-z][A-Z] should match a lowercase character followed immediately by an uppercase character

Upvotes: 2

Ben S
Ben S

Reputation: 69342

[A-Z][a-z]+ should do it.

Translation: Exactly one capital letter, followed by one or more lowercase letters.

Edit: I had the relationship backwards:

[a-z]+[A-Z]+

Translation: One or more lower-case letters, followed by one or more upper-case letters.

Upvotes: 2

Related Questions