At first this page may seem overkill as reader of these pages are assumed to know python already, but there are things that can be wrong with an installation and having notes on exactly how things work can be a useful resource for when there are problems. Python on Windows Installing Python. Python has an… Continue reading Installing & Launching
Category: a. basics
OOP: Using Kotlin to improve OOP Skills
Ok, Object Oriented Programming (OOP)is not exactly new, and there are lots of pages on OOP on the web. This page comes from a background of both Python and Kotlin, and how improved programming styles offered by Kotlin can change how you program. Although Kotlin automates newer techniques and provides assistance coding, you can 'backport'… Continue reading OOP: Using Kotlin to improve OOP Skills
Python to Kotlin: Variables and Types
Contents: python kotlin boxed objects vs unboxed primitives None, Nothing, Unit and null null safety Python Variables and Types As explained in the background, all values in python are objects stored in dynamic 'heap' memory, and variables are simply references to these objects. This means the only static or stack frame based information for any… Continue reading Python to Kotlin: Variables and Types
Nullable, null, None, Unit, Nothing and void: the many faces of nothing
Python has only one way of saying 'there is nothing here': None. Java has the keyword 'void' and the value 'null', kotlin has Unit, Nothing and null. What is the actual difference in meaning for all of these? Python None Kotlin Unit, null and Nothing Java void and null The concept of 'Nullable' Null Safety… Continue reading Nullable, null, None, Unit, Nothing and void: the many faces of nothing
var, val and Immutability
Why 'var' or 'val' at all? TL;DR: adding the 'var' (or val) is clearer than python syntax Python programs traditionally just set variables to a value, not fuss no extra step. Creating the variable by giving it a value uses the same syntax as setting an existing variable to a new value. Using the same… Continue reading var, val and Immutability