diff --git a/protocol/src/test/go/benchmark1.go b/protocol/src/test/go/benchmark1.go index d5b56eb5..96800cba 100644 --- a/protocol/src/test/go/benchmark1.go +++ b/protocol/src/test/go/benchmark1.go @@ -14,15 +14,15 @@ func main() { func test() { var startTime = time.Now() - var arr = []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13} const NUM int = 100000000 for i := 0; i < NUM; i++ { + var arr = []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13} bubbleSort(arr) } fmt.Println(time.Since(startTime).Milliseconds()) } -//排序 +// 排序 func bubbleSort(arr []int) { for j := 0; j < len(arr)-1; j++ { for k := 0; k < len(arr)-1-j; k++ { @@ -67,4 +67,4 @@ public class MainTest { } } } - */ +*/