Which programming languages can be used to develop in Android?

115,161

Solution 1

  • At launch, Java was the only officially supported programming language for building distributable third-party Android software.

  • Android Native Development Kit (Android NDK) which will allow developers to build Android software components with C and C++.

  • In addition to delivering support for native code, Google is also extending Android to support popular dynamic scripting languages. Earlier this month, Google launched the Android Scripting Environment (ASE) which allows third-party developers to build simple Android applications with perl, JRuby, Python, LUA and BeanShell. For having idea and usage of ASE, refer this Example link.

  • Scala is also supported. For having examples of Scala, refer these Example link-1 , Example link-2 , Example link-3 .

  • Just now i have referred one Article Here in which i found some useful information as follows:

    1. programming language is Java but bridges from other languages exist (C# .net - Mono, etc).
    2. can run script languages like LUA, Perl, Python, BeanShell, etc.

  • I have read 2nd article at Google Releases 'Simple' Android Programming Language . For example of this, refer this .

  • Just now (2 Aug 2010) i have read an article which describes regarding "Frink Programming language and Calculating Tool for Android", refer this links Link-1 , Link-2

  • On 4-Aug-2010, i have found Regarding RenderScript. Basically, It is said to be a C-like language for high performance graphics programming, which helps you easily write efficient Visual effects and animations in your Android Applications. Its not released yet as it isn't finished.

Solution 2

Here's a list of languages that can be used to develop on android:

  • Java - primary android development language

  • Kotlin, language from JetBrains which received first-party support from Google, announced in Google I/O 2017

  • C++ - NDK for libraries, not apps

  • Python, bash, et. al. - Via the Scripting Environment

  • Corona- One is to use the Corona SDK . Corona is a high level SDK built on the Lua programming language. Lua is much simpler to learn than Java and the SDK takes away a lot of the pain in developing Android app.

  • Cordova - which uses HTML5, JavaScript, CSS, and can be extended with Java

  • Xamarin technology - that uses c# and in which mono is used for that. Here MonoTouch and Mono for Android are cross-platform implementations of the Common Language Infrastructure (CLI) and Common Language Specifications.

As for your second question: android is highly dependent on it's java architecture, I find it unlikely that there will be other primary development languages available any time soon. However, there's no particular reason why someone couldn't implement another language in Java (something like Jython) and use that. However, that surely won't be easier or as performant as just writing the code in Java.

Solution 3

Scala is supported. See example.

Support for other languages is problematic:

7) Something like the dx tool can be forced into the phone, so that Java code could in principle continue to generate bytecodes, yet have them be translated into a VM-runnable form. But, at present, Java code cannot be generated on the fly. This means Dalvik cannot run dynamic languages (JRuby, Jython, Groovy). Yet. (Perhaps the dex format needs a detuned variant which can be easily generated from bytecodes.)

Solution 4

As stated above, many languages are available for developing in Android. Java, C, Scala, C++, several scripting languages etc. Thanks to Mono you are also able to develop using C# and the .Net framework. Here you have some speedcomparisions: http://www.youtube.com/watch?v=It8xPqkKxis

Solution 5

I made good experiences with Scala.

I use the simple build tool (sbt: http://code.google.com/p/simple-build-tool/) with the Android-Plugin (http://github.com/jberkel/android-plugin)

Share:
115,161
RoflcoptrException
Author by

RoflcoptrException

Updated on January 08, 2020

Comments

  • RoflcoptrException
    RoflcoptrException over 4 years

    Possible Duplicate:
    Which programming languages can I use on Android Dalvik?

    Mostly, Android applications are written in Java. But i heard that its also possible to use Scala or some other languages. And I also read that it's possible to include native C/C++ code.

    Is there a refernce/list available that shows which languages can be used?

  • inquam
    inquam almost 14 years
    Keep in mind that these comparisons are made using Android 1.5. Android 2.2 includes a JIT compiler that claims to improve the performance of Dalwin by 2-5x.
  • Paresh Mayani
    Paresh Mayani almost 14 years
    checkout..i have added new example links for scala
  • Paresh Mayani
    Paresh Mayani almost 14 years
    Checkout..i have added "frink Prog. for Android" detail
  • Paresh Mayani
    Paresh Mayani almost 14 years
    For having video regarding "Android Scripting Environment"....refer this links : slideshare.net/gasolin/…
  • Paresh Mayani
    Paresh Mayani almost 14 years
    On 4-aug-2010, i have added detail regarding "RenderScript for Android" detail
  • Admin
    Admin over 11 years
    Another info was missing just for the record, if someone do not need hardware access simply they can do quick HTML/CSS/JavaScript apps to save some time for small apps. e.g: youtube.com/watch?v=dc5xxN-awuE
  • Mark
    Mark almost 10 years
    "...as performant as Java..." sad to see that this sentence (as correct as it is in this case) exists
  • Seth
    Seth almost 10 years
    @Mark - "as performant as Java code running in the DalvikVM on a device designed to run Java code running in the DalvikVM." ... This comment wasn't intended to endorse Java as a programming language or to make general claims as to the performance or readability of said language. :)
  • Erik Pragt
    Erik Pragt over 9 years
    It's not so problematic anymore: github.com/groovy/groovy-android-gradle-plugin
  • Zasz
    Zasz over 8 years
    Kotlin from Jetbrains : github.com/JetBrains/kotlin
  • starbeamrainbowlabs
    starbeamrainbowlabs over 7 years
    That video is private :-\
  • Zibri
    Zibri over 5 years
    You forgot Chrome Progressive Web Apps developers.google.com/web/progressive-web-apps/desktop