1. 3
  1.  

  2. 1

    Note that measuring relative time between two events should always be done using nanoTime and never currentTimeMillis:

    currentTimeMillis is clock time, which changes due to daylight saving time, users changing the time settings, leap seconds, and internet time sync. If your app depends on monotonically increasing elapsed time values, you might prefer nanoTime instead.

    Source: https://stackoverflow.com/questions/351565/system-currenttimemillis-vs-system-nanotime