Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
get day of the month
Name: sunilmyneedi Date: November 23, 2006 at 02:29:10 Pacific OS: unix CPU/Ram: none Product: none
Comment:
how to get the day(mon,tue...)of 1st of the given month
Summary: Hi: This might work. There's something the mathematicans call "the rule of 7" or something like that. If you divide the day of the month by 7 and add 1, you'll get 1 unless the number is evenly divis...
Summary: Hi: Here's a way of doing it: #!/bin/ksh ddate="06/28/2003" # splits month, day, year into $1, $2, $3 respectively set - $(IFS="/"; echo $ddate) cal $1 $3|tail +3|head -1|awk ' { # $NF is a Saturday d...