Skip to content

Instantly share code, notes, and snippets.

@yunustek
Created October 7, 2018 16:55
Show Gist options
  • Save yunustek/57ad1a9e494afaecd16382dc8ab17104 to your computer and use it in GitHub Desktop.
Save yunustek/57ad1a9e494afaecd16382dc8ab17104 to your computer and use it in GitHub Desktop.
Random Sayı Üretimi
//generate a random number in the range 1 through 100
let randomInt = Int.random(in: 1..<100)
let randomFloat = Float.random(in: 1..<100)
let randomDouble = Double.random(in: 1…100)
let randomCGFloat = CGFloat.random(in: 1…100)
//generate a random bool
let randomBoolean = Bool.random()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment