Regex 2
Publish date: Mar 10, 2023
Last updated: Mar 12, 2023
Last updated: Mar 12, 2023
Problem
Make this:
SECTION 1. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Etiam fringilla, est sit amet congue vestibulum, sem nisi placerat libero, ac maximus metus dolor a lectus.
To this:
## SECTION 1
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Etiam fringilla, est sit amet congue vestibulum, sem nisi placerat libero, ac maximus metus dolor a lectus.
Solution
Search: (SECTION \d)\. ([a-zA-Z])
Replace: ## $1\n\n$2