Avatar
stderr:<stdin>:15:24: warning: expression implicitly coerced from 'Int?' to 'Any' print(type(of: y), y) // Optional<Int> nil ^ <stdin>:15:24: note: provide a default value to avoid this warning print(type(of: y), y) // Optional<Int> nil ^ ?? <#default value#> <stdin>:15:24: note: force-unwrap the value to avoid this warning print(type(of: y), y) // Optional<Int> nil ^ ! <stdin>:15:24: note: explicitly cast to 'Any' with 'as Any' to silence this warning print(type(of: y), y) // Optional<Int> nil ^ as Any (edited)