Skip to content

Commit beb19af

Browse files
sbaditheshripadbadithe
authored and
shripadbadithe
committed
Fix typo: "infomation" -> "information"
1 parent ce8d979 commit beb19af

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

_tour/regular-expression-patterns.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -107,11 +107,11 @@ key: width value: 100
107107

108108
Moreover, regular expressions can be used as patterns (in `match` expressions) to conveniently extract the matched groups:
109109

110-
{% tabs regex-patterns_saveContactInfomation class=tabs-scala-version %}
110+
{% tabs regex-patterns_saveContactInformation class=tabs-scala-version %}
111111

112-
{% tab 'Scala 2' for=regex-patterns_saveContactInfomation %}
112+
{% tab 'Scala 2' for=regex-patterns_saveContactInformation %}
113113
```scala mdoc
114-
def saveContactInfomation(contact: String): Unit = {
114+
def saveContactInformation(contact: String): Unit = {
115115
import scala.util.matching.Regex
116116

117117
val emailPattern: Regex = """^(\w+)@(\w+(.\w+)+)$""".r
@@ -127,15 +127,15 @@ def saveContactInfomation(contact: String): Unit = {
127127
}
128128
}
129129

130-
saveContactInfomation("123-456-7890")
131-
saveContactInfomation("[email protected]")
132-
saveContactInfomation("2 Franklin St, Mars, Milky Way")
130+
saveContactInformation("123-456-7890")
131+
saveContactInformation("[email protected]")
132+
saveContactInformation("2 Franklin St, Mars, Milky Way")
133133
```
134134
{% endtab %}
135135

136-
{% tab 'Scala 3' for=regex-patterns_saveContactInfomation %}
136+
{% tab 'Scala 3' for=regex-patterns_saveContactInformation %}
137137
```scala
138-
def saveContactInfomation(contact: String): Unit =
138+
def saveContactInformation(contact: String): Unit =
139139
import scala.util.matching.Regex
140140

141141
val emailPattern: Regex = """^(\w+)@(\w+(.\w+)+)$""".r
@@ -149,9 +149,9 @@ def saveContactInfomation(contact: String): Unit =
149149
case _ =>
150150
println("Invalid contact information, neither an email address nor phone number.")
151151

152-
saveContactInfomation("123-456-7890")
153-
saveContactInfomation("[email protected]")
154-
saveContactInfomation("2 Franklin St, Mars, Milky Way")
152+
saveContactInformation("123-456-7890")
153+
saveContactInformation("[email protected]")
154+
saveContactInformation("2 Franklin St, Mars, Milky Way")
155155
```
156156
{% endtab %}
157157

0 commit comments

Comments
 (0)