delete extra print

This commit is contained in:
Wenru Dong 2018-10-16 22:31:55 +01:00
parent 422b1a59bd
commit f52ce437b4

View File

@ -18,7 +18,6 @@ fileprivate func mergeSort<T>(_ a: inout T, from low: T.Index, to high: T.Index)
let mid = a.index(low, offsetBy: dist/2) let mid = a.index(low, offsetBy: dist/2)
mergeSort(&a, from: low, to: mid) mergeSort(&a, from: low, to: mid)
mergeSort(&a, from: a.index(mid, offsetBy: 1), to: high) mergeSort(&a, from: a.index(mid, offsetBy: 1), to: high)
print(a)
merge(&a, from: low, through: mid, to: high) merge(&a, from: low, through: mid, to: high)
} }
@ -48,7 +47,6 @@ fileprivate func merge<T>(_ a: inout T, from low: T.Index, through mid: T.Index,
var current = low var current = low
for element in tmp { for element in tmp {
a[current] = element a[current] = element
print(element)
a.formIndex(after: &current) a.formIndex(after: &current)
} }
} }