Plan 9 from Bell Labs’s /usr/web/sources/contrib/quanstro/timezone/gendstpairseu

Copyright © 2021 Plan 9 Foundation.
Distributed under the MIT License.
Download the Plan 9 distribution.


#!/bin/rc
pat = $1
if(~ $#pat 0)
	pat = '{print}'
fn q {
	seq $* | awk $pat
}
for(year in `{q 1977 1977})
	echo $year `{dateof -w1 $year apr sun 1>[2=]} `{dateof -w1 $year sep sun last>[2=]}
for(year in `{q 1978 1978})
	echo $year `{dateof -w1 $year apr sun 1>[2=]} `{dateof -w1 $year oct sun 1>[2=]}
for(year in `{q 1979 1980})
	echo $year `{dateof -w1 $year apr sun 1>[2=]} `{dateof -w1 $year sep sun last>[2=]}
for(year in `{q 1981 1995})
	echo $year `{dateof -w1 $year mar sun last>[2=]} `{dateof -w1 $year sep sun last>[2=]}
for(year in `{q 1996 2037})
	echo $year `{dateof -w1 $year mar sun last>[2=]} `{dateof -w1 $year oct sun last>[2=]}

Bell Labs OSI certified Powered by Plan 9

(Return to Plan 9 Home Page)

Copyright © 2021 Plan 9 Foundation. All Rights Reserved.
Comments to [email protected].