public static boolean sameDate(Calendar cal,Calendar selectedDate){
  return cal.get(Calendar.MONTH) == selectedDate.get(Calendar.MONTH) && cal.get(Calendar.YEAR) == selectedDate.get(Calendar.YEAR) && cal.get(Calendar.DAY_OF_MONTH) == selectedDate.get(Calendar.DAY_OF_MONTH);
}

public static boolean sameDate ( Calendar cal , Calendar selectedDate ) { return cal . get ( Calendar . MONTH ) == selectedDate . get ( Calendar . MONTH ) && cal . get ( Calendar . YEAR ) == selectedDate . get ( Calendar . YEAR ) && cal . get ( Calendar . DAY_OF_MONTH ) == selectedDate . get ( Calendar . DAY_OF_MONTH ) ; }
check if two calendar instances have the same time ( by month , year and day of month )
