Usually the studio uses the Java language. Can I program on Android using other languages? For example, the C language
- You can on Delphi, if you like wonders ;-) (starting with version XE5 emnip) - Kromster
- Look for game engines with Android support. - D-side
- To work with C / C ++, there is an Android NDK and support at the IDE level of Android Studio, including the native CLion code editor from JetBrains, built right into the studio, but the 100℅ native code cannot be obtained, since the Android framework itself is written in Java. - pavlofff
2 answers
You can use C / C ++ in the latest versions of Android Studio, but mostly only to optimize large computing and some low-level interactions with the system. The native UI and, in general, most of everything is written in Java and, accordingly, you can interact with it only through the languages copied into JVM code. In addition to Java itself, Kotlin, Groovy and Scala are most popular. For all three, there are plugins for Android Studio that add support for them.
If it's not important for you to use Android Studio, then I know another 3 IDEs for more native development under the android:
- Qt Creator (C ++) - uses its own library of visual components, so applications may not look quite "native".
- Embarcadero RAD Studio (Delphi) - for fans of the Delphi language, according to its capabilities it seems to be similar to Qt Creator, it also uses its component libraries.
- Microsoft Visual Studio + Xamarin Platform (C #) - in contrast to the two previous IDEs, there is no component library here, so-called binding to native Java classes are used here, so basically everything available to you is available from Java. There are truth and a few spoons of tar: C # is compiled into IL bytes code that runs in the mono virtual machine (the platform-based implementation of .NET), as a result we have two parallel-running virtual machines in one application, while the objects from the JVM with which we work from C # code Mono objects are wrapped in a proxy, as a result of which there are quite a few not obvious pitfalls. Although in general, the technology is quite workable and suitable.
Android NDK - The Native Development Kit for Android allows you to write in C / C ++