Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Java?.Kotlin!!
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
sebastian tellez
May 26, 2017
Programming
0
89
Java?.Kotlin!!
Platica para el meetup de Kotlin nights en la CDMX
sebastian tellez
May 26, 2017
Tweet
Share
Other Decks in Programming
See All in Programming
CSC307 Lecture 01
javiergs
PRO
0
690
Unicodeどうしてる? PHPから見たUnicode対応と他言語での対応についてのお伺い
youkidearitai
PRO
1
1.1k
今こそ知るべき耐量子計算機暗号(PQC)入門 / PQC: What You Need to Know Now
mackey0225
3
370
AIエージェント、”どう作るか”で差は出るか? / AI Agents: Does the "How" Make a Difference?
rkaga
4
2k
CSC307 Lecture 02
javiergs
PRO
1
770
登壇資料を作る時に意識していること #登壇資料_findy
konifar
3
920
フルサイクルエンジニアリングをAI Agentで全自動化したい 〜構想と現在地〜
kamina_zzz
0
400
AIエージェントのキホンから学ぶ「エージェンティックコーディング」実践入門
masahiro_nishimi
3
280
MUSUBIXとは
nahisaho
0
130
CSC307 Lecture 03
javiergs
PRO
1
490
フロントエンド開発の勘所 -複数事業を経験して見えた判断軸の違い-
heimusu
7
2.8k
Smart Handoff/Pickup ガイド - Claude Code セッション管理
yukiigarashi
0
120
Featured
See All Featured
Large-scale JavaScript Application Architecture
addyosmani
515
110k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.2k
The Limits of Empathy - UXLibs8
cassininazir
1
210
KATA
mclloyd
PRO
34
15k
Building Adaptive Systems
keathley
44
2.9k
A Tale of Four Properties
chriscoyier
162
24k
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
200
Docker and Python
trallard
47
3.7k
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
0
270
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
170
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
0
1.1k
Transcript
Java?.Kotlin!! Sebastian Tellez @gorrotowi github.com/gorrotowi
Java?.Kotlin!! Kotlin es un lenguaje de programación desarrollado por JetBrains.
Es funcional, esta diseñado para correr sobre la JVM, Android y Web
Java?.Kotlin!! Funcional Lambdas 100% interoperable con Java (JVM) NullSafety
Java?.Kotlin!! Ryan (James) Gosling a.k.a Java father
Java?.Kotlin!!
Java?.Kotlin!!
Java?.Kotlin!!
Java?.Kotlin!! private String numberString; int number = Integer.parseInt(numberString); //java
Java?.Kotlin!!
Java?.Kotlin!! private String numberString; if(numberString != null){ int number =
Integer.parseInt(numberString); } private String numberString; int number = Integer.parseInt(numberString); //java
Java?.Kotlin!! var a: String = "abc" a = null //
compilation error var b: String? = "abc" b = null // ok
Java?.Kotlin!! var a: String = "abc" val sizeA = a.length
var b: String? = "abc" b = null // ok var sizeB = b.length //error: variable 'b' can be null
Java?.Kotlin!! if (b != null && b.length > 0) {
print("String of length ${b.length}") } else { print("Empty string") }
Java?.Kotlin!! var a: String = "abc" val sizeA = a.length
var b: String? = "abc" b = null // ok var sizeB = b.length //error: variable 'b' can be null
Java?.Kotlin!! var sizeB = b?.length
Java?.Kotlin!! ?:
Java?.Kotlin!! val l = if (b != null) b.length else
-1
Java?.Kotlin!! val l = b?.length ?: -1
Java?.Kotlin!! fun foo(node: Node): String? { val parent = node.getParent()
?: return null val name = node.getName() ?: throw IllegalArgumentException("name expected") // ... }
Java?.Kotlin!! private String numberString; if(numberString != null){ int number =
Integer.parseInt(numberString); } private String numberString; int number = Integer.parseInt(numberString); //java //Kotlin
Java?.Kotlin!! val aInt: Int? = numberString as? Int //Kotlin
Java?.Kotlin!! val listWithNulls: List<String?> = listOf("A", null) for (item in
listWithNulls) { item?.let { println(it) } // prints A and ignores null }
Java?.Kotlin!! val fooFighters = b!!.length
Java?.Kotlin!!
Java?.Kotlin!! https://kotlinlang.org/docs/reference/ https://fabiomsr.github.io/from-java-to-kotlin/index.html https://try.kotlinlang.org/
Java?.Kotlin!! Sebastian Tellez @gorrotowi github.com/gorrotowi GRACIAS!!