How to calculate time complexity between code

            long t1 = System.nanoTime();
            long t2 = System.nanoTime();
            Log.v("","Time difference : "+(t2 - t1));
            Log.v("","Total time takes : "+(t2 - t1) * 1e-9);

Comments

Popular posts from this blog

RUN JAVA PROJECT IN ANDROID STUDIO

Gradle DSL method not found: 'compile()'

Reverse string using recursion