Section I: Programming Basics
Section II: Introduction to Objects
Section III: Usability
Section I: Programming Basics
Introduction
Why Kotlin ?
Kotlin เป็น compiler มากกว่า interpreted
การ compiler , source code จะถูก convert ไปเป็น different representation ซึ่งอาจจะโดยตรงใน hardware processor หรือใน virtual machine

program – C , C++ ,Rust , Go จะถูก compile เข้าไปเป็น machine code , run direct กับ CPU
ส่วน Java , Kotlin จะถูก compile เป็น bytecode เป็น intermediate-level ไม่ได้วิ่ง direct กับ CPU , แต่เป็น virtual machine eg JVM
เพราะฉะนั้น ทำให้ bytecode นี้สามารถ run ได้ในทุกๆ computer ที่มีการใส่ virtual machine นี้ลงไป
– ตอน compile time – จะมีการ check – compile-time errors , ถ้าปกติหมด ก็จะสร้างไปเป็น bytecode
– ส่วน runtime error – ไม่สามารถ detect ตอน compile ได้ , จะ detect ได้เฉพาะตอน run program ซึ่ง runtime-error ถือว่าเป็นขั้นตอนยาก และ expensive to fix
ส่วน statically-typed langauge eg Kotlin นี้ สามารถพบหลายๆ error ได้ตอน compile , แต่ถ้าเป็น dynamic language จะ perform ตอน safety check at runtime
Languaes that influenced Kotlin
p 14
Section II: Introduction to Objects
Section III: Usability
