https://kotlinlang.org logo
c

caspercba

06/08/2016, 9:30 AM
guys i was just about to suggest the same thing, but i was wondering whats the difference between:
Copy code
data?let {
it.doSomething()
}
and
Copy code
if ( data != null) {
data.doSomething()
}
for me case one looks prettier, but are there any other advantages?