question: public static String format ( long time_secs ) { if ( time_secs == Constants . CRAPPY_INFINITY_AS_INT || time_secs >= Constants . CRAPPY_INFINITE_AS_LONG ) return Constants . INFINITY_STRING ; if ( time_secs < 0 ) return "" ; int [ ] vals = { ( int ) time_secs % 60 , ( int ) ( time_secs / 60 ) % 60 , ( int ) ( time_secs / 3600 ) % 24 , ( int ) ( time_secs / 86400 ) % 365 , ( int ) ( time_secs / 31536000 ) } ; int end = vals . length - 1 ; while ( vals [ end ] == 0 && end > 0 ) { end -- ; } String result = vals [ end ] + TIME_SUFFIXES [ end ] ; end -- ; if ( end >= 0 ) result += " " + twoDigits ( vals [ end ] ) + TIME_SUFFIXES [ end ] ; return result ; }
target:  Format time into two time sections, the first chunk trimmed, the second with always with 2 digits.  Sections are *d, **h, **m, **s.  Section will be skipped if 0.   