できました。みなさんの合作という感じですね。もう寝ます。 <script> with(new Date)c=-new Date(y=getFullYear(),m=getMonth()).getDay(x=new Date(y,++m,0).getDate(b=-1)) h='<table border="1"><caption>'+y+'/'+m+'<tr>'+'日月火水木金土'.replace(/(.)/g,'<th>$1') while((b++>5?b=0:b)|c<x)h+=(b?'':'<tr>')+'<td>'+(++c<1|c>x?'-':c);document.write(h+'</table>') </script> この回答への補足 後世の人のために訳文を原文に復元してみました。^^; <html> <body> <script> var tmp = new Date