You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
321 B
22 lines
321 B
5 months ago
|
package cap3
|
||
|
|
||
|
import "fmt"
|
||
|
|
||
|
func _printMatrix(matrix [][]int) {
|
||
|
for _, row := range matrix {
|
||
|
for _, val := range row {
|
||
|
fmt.Printf("%d\t", val)
|
||
|
}
|
||
|
fmt.Println()
|
||
|
}
|
||
|
}
|
||
|
|
||
|
func _makeMatrix(size int) [][]int {
|
||
|
matrix := make([][]int, size)
|
||
|
for i := range matrix {
|
||
|
matrix[i] = make([]int, size)
|
||
|
}
|
||
|
|
||
|
return matrix
|
||
|
}
|