We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fc59325 commit 31d882fCopy full SHA for 31d882f
Roadmap/04 - CADENAS DE CARACTERES/go/kodenook.go
@@ -0,0 +1,25 @@
1
+package main
2
+
3
+import (
4
+ "fmt"
5
+ "strings"
6
+)
7
8
+func main() {
9
+ /*
10
+ String Functions
11
+ */
12
13
+ var word string = "hello, Go"
14
15
+ fmt.Println(strings.Contains(word, "hello"))
16
+ fmt.Println(strings.Count(word, "l"))
17
+ fmt.Println(strings.Index(word, "Go"))
18
+ fmt.Println(strings.LastIndex(word, "Go"))
19
+ fmt.Println(strings.Repeat(word, 2))
20
+ fmt.Println(strings.Replace(word, "Go", "Go!", 1))
21
+ fmt.Println(strings.ToLower(word))
22
+ fmt.Println(strings.ToUpper(word))
23
+ fmt.Println(strings.Trim(word, "eho"))
24
+ fmt.Println(strings.TrimSpace(word))
25
+}
0 commit comments