Int
struct Int : SignedInteger, Comparable, Equatable
-
Executes a block multiple times
Example:
3.times { print("Hello...") print("...you") }
Declaration
Swift
public func times (_ function: () -> ())
-
Converts to
String
Returns
theInt
as aString
Declaration
Swift
public func toString() -> String
Return Value
the
Int
as aString
-
Returns a random number within a
ClosedRange<Int>
(like1...10
)Returns
randomInt
Declaration
Swift
public static func randomNumber(range: ClosedRange<Int> = 1...6) -> Int
Return Value
random
Int