• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Jeanne Boyarsky
  • Liutauras Vilda
Sheriffs:
  • Rob Spoor
  • Bear Bibeault
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:
  • Frits Walraven
  • Himai Minh

Questions about Kotlin

 
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've played around with Java, but, lately, I've been looking for something that's not as verbose.

I'm looking for a language that's supported by Netbeans &/or Intellij. I don't want to use Eclipse because there's no graphical user install for my Mac. The less I have to fool with the Terminal, the better I like it.

I don't want to learn Groovy because there's no graphical install for my Mac.

Initially I was intrigued by Python/Jython. It's easy to read.

Yet, the more research I did, the less intrigued I was.

It's dynamically typed. One can change the data type in a variable & the compiler won't complain. That's lazy programming.

There's no concept of constants in Python. I read that tuples are immutable so one can call, say, the value of pi from the tuple. I suppose that tuples are similar to arrays in that you need to know the index before you can call the value. I'd rather create a constant.

Python code has to be separate from Java code or the compiler will complain. That would confuse me.

So, I'm narrowing down my choices for a Java VM compatible language to either Kotlin or Scala. I read that Scala has a steep learning curve.

So, here I go with the questions!

Barnes & Noble is the only bookstore in my town. I've seen plenty of books on Android development but none on Scala or Kotlin.

Is the Kotlin syntax for Android identical to "regular" Kotlin syntax? Can I teach myself Kotlin by using Android development books even though I probably won't develop any Android apps?

I know that the Intellij IDE will convert Java to Kotlin, but can one mix Java source code with Kotlin source code in the same file or will the compiler complain?
 
Ranch Hand
Posts: 76
3
IntelliJ IDE Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello, David.

First of all, I would direct you to this post, as it is sure to come in handy: https://coderanch.com/wiki/666092/Kotlin/started-Kotlin

As for your questions. Many books/tutorials on Android programming using Kotlin will probably reference some library with extension functions made specifically for Android programming. Whether this will affect learning the language itself, I cannot tell. I would, however, urge you to go through the entire official Kotlin reference to get a grasp on the language syntax. If you already know Java it should not be too difficult.

Good luck
 
I don't even know how to spell CIA. But this tiny ad does:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
reply
    Bookmark Topic Watch Topic
  • New Topic