This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| fun main() { | |
| println() | |
| val base = 25000 // Monthly pay | |
| val growth0 = arrayOf(0f, 0.05f, 0.05f, 0.05f, 0.05f) // Growth rate | |
| val durations0 = arrayOf(12, 12, 12, 12, 12) // Months | |
| print(base, growth0, durations0, "5 Years") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import android.content.Context | |
| import io.reactivex.Completable | |
| import io.reactivex.schedulers.Schedulers | |
| import timber.log.Timber | |
| import java.io.BufferedWriter | |
| import java.io.File | |
| import java.io.FileWriter | |
| import java.io.IOException | |
| object TextFileLogger { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package x.y | |
| import java.util.* | |
| import kotlin.math.log2 | |
| fun main() { | |
| val array: Array<Int?> = arrayOf(6, 7, 8, 2, 7, 1, 3, 9, null, 1, 4, null, null, null, 5) | |
| val root = insertLevelOrder(array, 0) | |
| val depth = log2(array.size.toDouble()).toInt() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package x.y | |
| fun main(args: Array<String>) { | |
| loops() | |
| stringAndArrays() | |
| arrays() | |
| } |
OlderNewer