Subscribe for notification
Categories: Android Tutorial

Learn Kotlin using Kotlin Koans & REPL(Read, Eval, Print, Loop)

Kotlin’s popularity continues to grow, and there’s never been a better time to start using & learning the language. Thankfully, Kotlin is surprisingly easy to try out. You can try it in a browser. It’s supported my multiple IDEs. You can learn on your own in a new project, or walk through sample exercises with a guided learning plugin. This posts collects a number of those resources so you can pick what works best for you.

Scratches let us create code drafts in the same IDE window as our project and run them on the fly. Scratches are not tied to projects; you can access and run all your scratches from any IntelliJ IDEA window on your OS. To create a Kotlin scratch, click File | New | Scratch file and select the Kotlin type.

In turn, worksheets are project files: they are stored in project directories and tied to the project modules. Worksheets are useful for writing code parts that don’t actually make a software unit but should still be stored together in a project. For example, you can use worksheets for education or demo materials.

To create a Kotlin worksheet in a project directory, right-click the directory in the project tree and select New | Kotlin Worksheet.

In scratches and worksheets, you can write any valid Kotlin code. Syntax highlighting, auto-completion, and the other IntelliJ IDEA code editing features are all supported too. Note that there’s no need for declaring the main function: all the code you write is executed as if it would be in the body of main.

Once you have finished writing your code in a scratch or a worksheet, click Run. The execution results will appear in the lines opposite your code.

Sponsored
SyncSaS

SyncSaS Technologies is specialized in creating and designing customized software. We have our own team that will be in charge of developing your softwares.

Share
Published by

Recent Posts

Adsense Updated Dashboard

Changes in Adsense Dashboard Recently you might have seen few changes in Adsense dashboard, these…

3 weeks ago

Guide Book For Google Adsense

With my experience in working as AdSense publisher, I have written many articles, tutorials for…

3 weeks ago

How to manage Google Adsense to get High CPC

Manage Adsense for High CPC CPC (Cost per click) in simple words the CPC is…

3 weeks ago

Google Adsense Introduce page level ads

If you are already the publisher of Google Adsense account then now its time to…

3 weeks ago