SlideShare a Scribd company logo
1 of 15
KOTLIN
HI
2
ROBERT
MACLEAN
@rmaclean
REQUIRED ADVERTISING
You can click next in 5 seconds…
3
• Kotlin History
• How I’m Learning Kotlin
• [ INTERACTIVE DEMO ]
• Remember demos aren’t real
• Problems
4
AGENDA
The WYSIWYG slide
• Started in 2010
• Version 1 in 2016
• Developed by JetBrains
• Built in response to real
development pains
• Borrows from other languages
• Built on the JVM
• Sum of the parts
• First class support from Google
• Hybrid language
• Not pure OO
• Not pure functional
5
KOTLIN HISTORY
I have clothes older than this…
• IntelliJ
• Android Studio
• VIM
• Sublime
• Code
• Atom
• Eclipse
• Netbeans
6
YOUR FAVOURITE EDITOR SUPPORTS IT
Unless your favourite is Fat Visual Studio
• Normal Person
• Basic  Pascal  Delphi 
PHP  Perl  C#  JavaScript
 TypeScript  Java
• Where do I begin?
7
HOW IAM LEARNING KOTLIN
How awkward would it be if I didn’t know it….
KOANS
Out of nowhere, the
mind comes forth.
— The Diamond Sutra
8
• Simple “game”
• Start with a grid of alive & dead
cells
• 4 rules
• Under population: Any live cell
with < 2 neighbours dies
• Any live cell with 2 or 3
neighbours lives
• Over population: Any live cell
with > 3 neighbours dies
• Reproduction: Any dead cell with
exactly 3 neighbours comes to life
9
GAME OF LIFE
Background for the big demo
TRUE: 3 neighbours it lives
TRUE: 2 neighbours & was
already alive, stays alive
FALSE: Everything else dies
• Grid is an array of booleans in an
array
• Render
• Draw to the screen
• Evolve
• Make a new grid
• Go though each cell
• Count how many neighbours it has
• Apply rules to new grid
• Replace the existing grid
• Repeat
10
GAME OF LIFE
Big demo time
GAME OF LIFE
Shall we play a game
11
• Getters & Setters
• Null Safety
• When
• Inheritance
• High Order Functions
• by (delegated properties)
• todo
• Reflection
• Making your own Operators
• String Templates
• Backticks
12
OTHER THINGS
In no particular order
• JetBrains
• Interoperability hacks
• “Kt” suffix on classes
• Kotlin to JS
• Lack of static
• Maybe
• Is it not opinionated enough?
13
PROBLEMS
Is Kotlin Perfect?
https://github.com/JetBrains/kotlin-workshop
https://kotlin.link
https://try.kotlinlang.org
https://github.com/Kotlin/kotlin-koans
https://github.com/gradle/kotlin-
dsl/tree/master/samples
https://kotlinlang.org/docs/reference/idioms.ht
ml
http://bit.ly/kotlinhelp
14
MORE RESOURCES
I know it is too small to read; grab these slides from me
THANK YOU
Robert MacLean @rmaclean
www.sadev.co.za
15

More Related Content

Similar to Kotlin 101

Watch Your Language! - What my Mother Taught Me about Being an Engineer.
Watch Your Language! - What my Mother Taught Me about Being an Engineer.Watch Your Language! - What my Mother Taught Me about Being an Engineer.
Watch Your Language! - What my Mother Taught Me about Being an Engineer.
Neal Richardson Sr
 
Kernel Development: Drawing Lessons From "Mistakes" (Japan Linux Symposium 2009)
Kernel Development: Drawing Lessons From "Mistakes" (Japan Linux Symposium 2009)Kernel Development: Drawing Lessons From "Mistakes" (Japan Linux Symposium 2009)
Kernel Development: Drawing Lessons From "Mistakes" (Japan Linux Symposium 2009)
guest40cf23
 
OGDC 2014: Architecting Games in Unity
OGDC 2014: Architecting Games in UnityOGDC 2014: Architecting Games in Unity
OGDC 2014: Architecting Games in Unity
GameLandVN
 
OGDC 2014_Architecting Games in Unity_Mr. Rustum Scammell
OGDC 2014_Architecting Games in Unity_Mr. Rustum ScammellOGDC 2014_Architecting Games in Unity_Mr. Rustum Scammell
OGDC 2014_Architecting Games in Unity_Mr. Rustum Scammell
ogdc
 

Similar to Kotlin 101 (20)

Making A Game Engine Is Easier Than You Think
Making A Game Engine Is Easier Than You ThinkMaking A Game Engine Is Easier Than You Think
Making A Game Engine Is Easier Than You Think
 
There Is No JavaScript
There Is No JavaScriptThere Is No JavaScript
There Is No JavaScript
 
Noam Kfir - There is no Java Script - code.talks 2015
Noam Kfir - There is no Java Script - code.talks 2015Noam Kfir - There is no Java Script - code.talks 2015
Noam Kfir - There is no Java Script - code.talks 2015
 
Test-Driven Sitecore
Test-Driven SitecoreTest-Driven Sitecore
Test-Driven Sitecore
 
Programming with Kotlin
Programming with KotlinProgramming with Kotlin
Programming with Kotlin
 
Things you should know if you plan to ship a game
Things you should know if you plan to ship a gameThings you should know if you plan to ship a game
Things you should know if you plan to ship a game
 
Understand Java for Android the Hard Way
Understand Java for Android the Hard WayUnderstand Java for Android the Hard Way
Understand Java for Android the Hard Way
 
Low-level concurrency (reinvent vehicle)
Low-level concurrency (reinvent vehicle)Low-level concurrency (reinvent vehicle)
Low-level concurrency (reinvent vehicle)
 
Functional Programming in Clojure
Functional Programming in ClojureFunctional Programming in Clojure
Functional Programming in Clojure
 
Watch Your Language! - What my Mother Taught Me about Being an Engineer.
Watch Your Language! - What my Mother Taught Me about Being an Engineer.Watch Your Language! - What my Mother Taught Me about Being an Engineer.
Watch Your Language! - What my Mother Taught Me about Being an Engineer.
 
Kernel Development: Drawing Lessons From "Mistakes" (Japan Linux Symposium 2009)
Kernel Development: Drawing Lessons From "Mistakes" (Japan Linux Symposium 2009)Kernel Development: Drawing Lessons From "Mistakes" (Japan Linux Symposium 2009)
Kernel Development: Drawing Lessons From "Mistakes" (Japan Linux Symposium 2009)
 
OGDC 2014: Architecting Games in Unity
OGDC 2014: Architecting Games in UnityOGDC 2014: Architecting Games in Unity
OGDC 2014: Architecting Games in Unity
 
A Prelude to Android
A Prelude to AndroidA Prelude to Android
A Prelude to Android
 
Concurrency in Python
Concurrency in PythonConcurrency in Python
Concurrency in Python
 
David Brevik - LOGIN Conference 2012
David Brevik - LOGIN Conference 2012David Brevik - LOGIN Conference 2012
David Brevik - LOGIN Conference 2012
 
Enterprise Strength Mobile JavaScript
Enterprise Strength Mobile JavaScriptEnterprise Strength Mobile JavaScript
Enterprise Strength Mobile JavaScript
 
Kotlin Multiplatfom In Action
Kotlin Multiplatfom In ActionKotlin Multiplatfom In Action
Kotlin Multiplatfom In Action
 
Kotlin Multiplatfom In Action
Kotlin Multiplatfom In ActionKotlin Multiplatfom In Action
Kotlin Multiplatfom In Action
 
3 years with Clojure
3 years with Clojure3 years with Clojure
3 years with Clojure
 
OGDC 2014_Architecting Games in Unity_Mr. Rustum Scammell
OGDC 2014_Architecting Games in Unity_Mr. Rustum ScammellOGDC 2014_Architecting Games in Unity_Mr. Rustum Scammell
OGDC 2014_Architecting Games in Unity_Mr. Rustum Scammell
 

More from Robert MacLean

More from Robert MacLean (20)

14 things you need to be a successful software developer (v3)
14 things you need to be a successful software developer (v3)14 things you need to be a successful software developer (v3)
14 things you need to be a successful software developer (v3)
 
Git
GitGit
Git
 
OWASP TOP 10
OWASP TOP 10OWASP TOP 10
OWASP TOP 10
 
Building a µservice with Kotlin, Micronaut & GCP
Building a µservice with Kotlin, Micronaut & GCPBuilding a µservice with Kotlin, Micronaut & GCP
Building a µservice with Kotlin, Micronaut & GCP
 
Looking at the Vue
Looking at the VueLooking at the Vue
Looking at the Vue
 
Features of Kotlin I find exciting
Features of Kotlin I find excitingFeatures of Kotlin I find exciting
Features of Kotlin I find exciting
 
JavaScript Gotchas
JavaScript GotchasJavaScript Gotchas
JavaScript Gotchas
 
DevConf Survival Guide
DevConf Survival GuideDevConf Survival Guide
DevConf Survival Guide
 
The state of testing @ Microsoft
The state of testing @ MicrosoftThe state of testing @ Microsoft
The state of testing @ Microsoft
 
Visual Studio ❤ JavaScript
Visual Studio ❤ JavaScriptVisual Studio ❤ JavaScript
Visual Studio ❤ JavaScript
 
What is new in C# 6?
What is new in C# 6?What is new in C# 6?
What is new in C# 6?
 
Putting the DOT in .NET - Dev/Ops/Test
Putting the DOT in .NET - Dev/Ops/TestPutting the DOT in .NET - Dev/Ops/Test
Putting the DOT in .NET - Dev/Ops/Test
 
A Developer Day 2014 - Durban
A Developer Day 2014 - Durban A Developer Day 2014 - Durban
A Developer Day 2014 - Durban
 
Agile lessons learned in the Microsoft ALM Rangers
Agile lessons learned in the Microsoft ALM RangersAgile lessons learned in the Microsoft ALM Rangers
Agile lessons learned in the Microsoft ALM Rangers
 
Hour of code - Train the trainer
Hour of code - Train the trainerHour of code - Train the trainer
Hour of code - Train the trainer
 
Building services for apps on a shoestring budget
Building services for apps on a shoestring budgetBuilding services for apps on a shoestring budget
Building services for apps on a shoestring budget
 
3 things your app API is doing WRONG
3 things your app API is doing WRONG3 things your app API is doing WRONG
3 things your app API is doing WRONG
 
ASP.NET
ASP.NETASP.NET
ASP.NET
 
LightSwitch
LightSwitchLightSwitch
LightSwitch
 
How to build a Mobile API or HTML 5 app in 5 minutes
How to build a Mobile API or HTML 5 app in 5 minutesHow to build a Mobile API or HTML 5 app in 5 minutes
How to build a Mobile API or HTML 5 app in 5 minutes
 

Recently uploaded

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Recently uploaded (20)

ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 

Kotlin 101