Getting "Argument passed to call that takes no arguments" when trying to use arc4random

189 views Asked by At

I am making a simple guessing game in Swift, and have been using arc4random to generate a random number. However, when I run the app, it fails and gives me the error message "Argument passed to call that takes no arguments." The code that receives the error message is below:

var randomNumber = arc4random(50) + 1

I am fairly new to Swift, so please enlighten me!

0

There are 0 answers