Explaining here , How Gradle LifeCycle Works during build phase:

1.) Initialization Phase (Setting.gradle file) -> All Projects are listed in this file since it is required to make new Instance for every module Project so that Gradle can make queue to run build.gradle …

Given an array of positive numbers, where each element represents the max number of jumps that can be made forward from that element, write a program to find the minimum number of jumps needed to reach the end of the array (starting from the first element). If an element is 0, then we cannot move through that element.

package practice;

public class ArrayJump {

public int countMinJumps(int[] jumps) {

if (jumps == null || jumps.length < 2) {
return 0;
int[] minJumps = new int[jumps.length];
minJumps[0] = 0;
for (int i = 1; i < minJumps.length; i++) {…

I am writing the basic cache technique here to make it faster, Thread Safe, and with cache Expiry Support.

Component used:

  1. LinkedHashMap

a.) For saving Entry in map to get value in O(1)

b.) To remove oldest entry from Cache map if size exceeds from a limit with accessOrder property…

When to use WorkManager:

1.) If Task is defferable , repeated with no exact time, Need to be completed sure even on Reboot, Then use WorkManager.

2.) If any work is triggered online, use Push Notification to trigger WorkManager Work.

3.) If you want to send Data instantly from Mobile…

In this post , I just want to give basic understanding for those who just started the memory Profiling to optimise memory for Android.

Android kernel was first developed it and it was based on Linux-Kernel. …

public static String[] ternaryTreePaths(Node root) {
if(root== null ) return null;
ArrayList<String> al = new ArrayList<String>();
ArrayList<String> res = new ArrayList<String>();
dfs(root, al, res);
return res.toArray(new String[res.size()]);

public static void dfs(Node root, ArrayList<String> list, ArrayList<String> res){…

Amit Gupta

Principal Software Engineer , Mobile Engineering

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store