Thank you, now I have to digest this. Thanks for the help. Much appreciated.
for the last day of October
Code:
echo $(cal 10 2011) | awk '{print $NF}'
for the last day with of October including name of the day
Code:
cal 10 2011|sort -nr | awk 'FNR==1{a=NF;b=$NF}/^[^ [:digit:]]/{print $a,b}'