Java Day Convert To daysToYears(int days)

Here you can find the source of daysToYears(int days)

Description

days To Years

License

Apache License

Declaration

public static String daysToYears(int days) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static String daysToYears(int days) {
        int years = days / 365;
        int leftOvers = days - (years * 365);
        String total = String.valueOf(years) + ":" + String.valueOf(leftOvers);
        return total;
    }/*from   w  w  w  .  ja  va  2s  .  c o m*/
}

Related

  1. day2doy(int year, int month, int mday)
  2. day2msec(int day)
  3. day2String(int dayofweek)
  4. daysToSecs(long days)
  5. daysToTicks(double x)