Created
May 26, 2019 21:22
-
-
Save Mreyna3/7064ce8254de61c4dd2a841b3cdd8a13 to your computer and use it in GitHub Desktop.
processBatch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func processBatch(){ | |
// 1 | |
for _ in 0..<queue.getCount(){ | |
// 2 | |
batchSum -= queue.peek()! | |
print("deueuing \(queue.dequeue()!)") | |
} | |
print("deueuing \(batchSum!)") | |
// 3 | |
resetBatchSum() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment