good course by Kirill

This commit is contained in:
a.pivkin 2025-07-08 18:47:29 +03:00
parent 28109f35f6
commit 5ae2318fb9
5 changed files with 38 additions and 0 deletions

3
Lec4/go.mod Normal file
View File

@ -0,0 +1,3 @@
module main.go
go 1.24.4

15
Lec4/main.go Normal file
View File

@ -0,0 +1,15 @@
package main
import (
"fmt"
"unicode/utf8"
"unsafe"
)
func main() {
var kek string = "Федя"
fmt.Printf("Length of %s is: %d\n",kek,len(kek))
fmt.Printf("Length in chars: %d\n",utf8.RuneCountInString(kek))
fmt.Printf("Type %T size of %d bytes\n",kek,unsafe.Sizeof(kek))
}

3
Lec5/go.mod Normal file
View File

@ -0,0 +1,3 @@
module main.go
go 1.24.4

17
Lec5/main.go Normal file
View File

@ -0,0 +1,17 @@
package main
import (
"fmt"
"strings"
)
func main() {
var word1 string
fmt.Scan(&word1)
if strings.Contains(word1,"чат") {
fmt.Println("THIS IS BOT")
return
}
fmt.Println("This is not a bot")
}

0
pkg/mod/cache/lock vendored Normal file
View File