Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我使用“attaswift/Deque”库。我有一个双双端队列;
var pointsZ = Deque<Double>()
我想用;
for (index,value) in pointsZ.enumerated(){ ... }
我在 Xcode 11.4.1中收到错误“For-in 循环需要EnumeratedSequence<Deque<Double>>符合”。Sequence如何解决这个问题?
EnumeratedSequence<Deque<Double>>
Sequence
我改变了我的for循环;
for i in 0..<pointsZ.count { print(pointsZ[i]) }
它解决了我的问题。