Code for ndk example