Updated (for clarity and to reduce ambiguity):
I'm going to start working on Android apps. I planned to write in C ++ using the NDK (since I have more experience in C ++ and I prefer it in Java), but on the Android NDK page:
you should use only NDK if it is important for your app - never, because you just prefer to program in C / C ++.
I got the impression that you should use the language that you prefer, if it is suitable for work. Can someone explain why it is so strongly not recommended to use C / C ++ for Android development?
Original:
I'm going to start working on mobile applications, in particular, android, which is the OS of my current phone, and I was wondering if writing an application in C ++ (or at least the kernel, and then wrapping it in Java) is an acceptable option.
In some ways, I am an IT specialist who took 3 courses in C ++ (input, intermediate, OOP, and I take the STL course in spring) and only 1 Java course (intermediate). Because of this, I like C ++ more and prefer it to Java. I came across the following Android NDK page:
Using native code on Android does not usually result in a noticeable increase in performance, but it always increases the complexity of your application. In general, you should only use NDK if it is important for your app - never, because you just prefer to program in C / C ++.
- I got the impression that you should use a language, a suitable job, as well as one with which you are familiar
- Maybe I want to transfer the application to another mobile platform, such as iOS, which supports C ++, but not java
- Although Java is a high-level language and therefore should be faster, I feel that development will be slower because I would retrain almost everything (since I took only one class per language)
Any advice would be greatly appreciated.
ps: many answers to this topic are taken from several years ago, and there are very few answers to subsequent answers that mention the NDK, which allows you to develop full-fledged applications on Android 2.3 and newer.
java c ++ android
Logan Besecker Dec 08 2018-12-12T00: 00Z
source share