From 6423f9810c7facce409c21029544aa397ba4a6a5 Mon Sep 17 00:00:00 2001 From: Angelos Chalaris Date: Wed, 2 Oct 2019 09:42:29 +0300 Subject: [PATCH] Update snake.md --- snippets/snake.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/snippets/snake.md b/snippets/snake.md index a5b296c5e..4aa3f83fe 100644 --- a/snippets/snake.md +++ b/snippets/snake.md @@ -11,9 +11,9 @@ Break the string into words and combine them adding `_` as a separator, using a import re def snake(str): - return '_'.join(re.sub('([A-Z][a-z]+)', r' \1', - re.sub('([A-Z]+)', r' \1', - str.replace('-', ' '))).split()).lower() + return '_'.join(re.sub('([A-Z][a-z]+)', r' \1', + re.sub('([A-Z]+)', r' \1', + str.replace('-', ' '))).split()).lower() ``` ```py