func createRandomNumber (length: Int) -> String
{
var seed: String = "0123456789"
var number: String = ""
for _ in 0..length {
var index = Int (arc4random_uniform (10)) % seed.length ()
number = number + seed.substringAt (index: index)
seed = seed.remove (from: index, length: 1)
}
return number
}
func createRandomNumber (length: Int) -> String
{
var seed: String = "0123456789"
var number: String = ""
for _ in 0..length {
var index = Int (arc4random_uniform (10)) % seed.length ()
number = number + seed.substringAt (index: index)
seed = seed.remove (from: index, length: 1)
}
return number
}
func createRandomNumber (length: Int) -> String
{
var seed: String = "0123456789"
var number: String = ""
for _ in 0..length {
var index = Int (arc4random_uniform (10)) % seed.length ()
number = number + seed.substringAt (index: index)
seed = seed.remove (from: index, length: 1)
}
return number
}
func createRandomNumber (length: Int) -> String
{
var seed: String = "0123456789"
var number: String = ""
for _ in 0..length {
var index = Int (arc4random_uniform (10)) % seed.length ()
number = number + seed.substringAt (index: index)
seed = seed.remove (from: index, length: 1)
}
return number
}
func createRandomNumber (length: Int) -> String
{
var seed: String = "0123456789"
var number: String = ""
for _ in 0..length {
var index = Int (arc4random_uniform (10)) % seed.length ()
number = number + seed.substringAt (index: index)
seed = seed.remove (from: index, length: 1)
}
return number
}
func createRandomNumber (length: Int) -> String
{
var seed: String = "0123456789"
var number: String = ""
for _ in 0..length {
var index = Int (arc4random_uniform (10)) % seed.length ()
number = number + seed.substringAt (index: index)
seed = seed.remove (from: index, length: 1)
}
return number
}
Like this:
Like Loading...