RosettaCodeData/Task/Regular-expressions/Elixir/regular-expressions-3.ex
2024-10-16 18:07:41 -07:00

2 lines
103 B
Elixir

str1 = ~r/a/ |> Regex.replace(str,"another")
str2 = str1 |> String.replace(~r/another/,"even another")