Generate a random number


I want to generate a random number, between 0 and N-1.


// Generate a random number
// between 0 and 9 (10-1)

let rand = Int(arc4random_uniform(10))



Programming Tip : Migrate your programming/testing environment into the cloud by loading your essential programming tools on high performance citrix vdi from CloudDesktopOnline with remote accessibility from anywhere on any device(PC/android/iOS). To learn more about innovate cloud apps such as Hosted SharePoint, Exchange and managed azure services visit Apps4Rent.

Find answers here

Hi there! Ask Us a Question We are ready to help