/r/learnkotlin

Photograph via snooOG

/r/learnkotlin

907 Subscribers

2

Calling main() in a kts file.

Hi everyone! I recently started learning Kotlin for an intro to cs class at university and I had a quick question on why I have to call the main() function even though it is already established as a function in kts file. For example:

https://preview.redd.it/bxym5bk9zonb1.png?width=790&format=png&auto=webp&s=f68180723ae908e7a5f131b7397809d1be8f9534

Without main() nothing displays in the terminal. Why is this the case?

1 Comment
2023/09/11
21:11 UTC

1

Intro to Kotlin Coroutines

Been digging further into Kotlin Coroutines and wanted to create a video from what I learned

0 Comments
2023/06/04
15:36 UTC

5

Building a Full Stack Web Application with Kotlin and React

0 Comments
2023/05/08
08:16 UTC

4

New developers - Join an open source project!

Hi Kotlin developers,

I'm building an SDK in Kotlin for an open source project. Are there any developers here that are looking to contribute to an open source project with Kotlin? If you are, checkout the repo and if you find it interesting, fork and send a PR and lets build something awesome! This is my first project where I build an SDK in Kotlin so all inputs are awesome!

If you are interested or just want to support me, check out my project and give a star to give me some support going forward! 🙏

GitHub link: https://github.com/kryptokrona/kryptokrona-kotlin-sdk

Cheers!

0 Comments
2023/04/09
19:56 UTC

0

Can't find the main method in codebase

Hey all, I was just hired on to an IT help desk role, and I learn about programming as a hobby. My work has a software dev division, and I've asked them politely to see their codebase. They let me, and I've pulled it down from GitLab, but here's the thing - I can't find the main method! Haha

I've found the kotlin class files, and I just finished scanning through them. I'm just wondering if I'm missing something obvious about how Kotlin works. The languages I've studied are java, javascript, and C. (and HTML/CSS)

This is my first time exploring a real codebase, any help would be super appreciated. Thank you!

6 Comments
2023/01/14
20:52 UTC

0

What is a domain gateway, why do you need it, and how to build it?

0 Comments
2022/12/14
07:49 UTC

1

Get () explanation

Hello all,

Here is the line in question: private val binding get() = _binding!!

I did some reading on get() and from what I understand this is implementing a custom getter. My background is in Java, and I understand a getter to retrieve some property of an object. I.e. MyObject.getName()

Can someone shed some light on this please?

1 Comment
2022/10/10
15:31 UTC

Back To Top