get last day of given month

two methods to get last day of given month;
one is traditional and effective methods;
another one is tricky with Date Object