So i have a problem using the Switch statement, when i used it with a range i get this "Fatal error: Range end index has no valid successor" in the console.
var ArrayBytes : [UInt8] = [48 ,48 ,48]
var SuperArrayMensaje : Array = [[UInt8]]()
var num7BM : Array = [UInt8]()
for var Cont27 = 0; Cont27 < 800; Cont27++ {
ArrayBytesReservaSrt = String(Mensaje7BM[Cont27])
switch Mensaje7BM[Cont27] {
case 0...9 :
num7BM = Array(ArrayBytesReservaSrt.utf8)
ArrayBytes.insert(num7BM[0], atIndex: 2)
case 10...99 :
num7BM = Array(ArrayBytesReservaSrt.utf8)
ArrayBytes.insert(num7BM[0], atIndex: 1)
ArrayBytes.insert(num7BM[1], atIndex: 2)
case 100...255 : // --> THE problem is here "EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0)"
num7BM = Array(ArrayBytesReservaSrt.utf8)
ArrayBytes.insert(num7BM[0], atIndex: 0)
ArrayBytes.insert(num7BM[1], atIndex: 1)
ArrayBytes.insert(num7BM[2], atIndex: 2)
default : break
}
SuperArrayMensaje.insert(ArrayBytes, atIndex: Cont27)
ArrayBytes = [48 ,48 ,48]
}