質問編集履歴
1
3つ目のコードのif文が「if countB == checkCount {」になっていたので「if countB == checkCountB {」に直しました。
title
CHANGED
File without changes
|
body
CHANGED
@@ -65,7 +65,7 @@
|
|
65
65
|
var checkCountB = 0
|
66
66
|
while countB < 3 {
|
67
67
|
if countB == checkCountB {
|
68
|
-
|
68
|
+
checkCountB += 1
|
69
69
|
// 時間遅れに揺らぎ(0.5秒から1.0秒の間)を与える
|
70
70
|
let delay = Double.random(in: 0.5...1.0)
|
71
71
|
dispatchQueue.asyncAfter(deadline: .now() + delay) {
|