#include <stdio.h>
int main() {
int days_in_month = 30, first_day = 2; // วันแรกตรงกับอังคาร (2)
printf("Sun Mon Tue Wed Thu Fri Sat\n");
// พิมพ์ช่องว่างจนถึงวันแรก
int i;
for (i = 1; i < first_day; i++) {
}
// พิมพ์วันที่
for (int day = 1; day <= days_in_month; day++) {
// ถ้าครบ 7 วันให้ขึ้นบรรทัดใหม่
if ((day + first_day - 1) % 7 == 0) {
}
}
return 0;
}
I2luY2x1ZGUgPHN0ZGlvLmg+CgppbnQgbWFpbigpIHsKICAgIGludCBkYXlzX2luX21vbnRoID0gMzAsIGZpcnN0X2RheSA9IDI7IC8vIOC4p+C4seC4meC5geC4o+C4geC4leC4o+C4h+C4geC4seC4muC4reC4seC4h+C4hOC4suC4oyAoMikKICAgIAogICAgcHJpbnRmKCJTdW4gTW9uIFR1ZSBXZWQgVGh1IEZyaSBTYXRcbiIpOwoKICAgIC8vIOC4nuC4tOC4oeC4nuC5jOC4iuC5iOC4reC4h+C4p+C5iOC4suC4h+C4iOC4meC4luC4tuC4h+C4p+C4seC4meC5geC4o+C4gQogICAgaW50IGk7CiAgICBmb3IgKGkgPSAxOyBpIDwgZmlyc3RfZGF5OyBpKyspIHsKICAgICAgICBwcmludGYoIiAgICAiKTsKICAgIH0KCiAgICAvLyDguJ7guLTguKHguJ7guYzguKfguLHguJnguJfguLXguYgKICAgIGZvciAoaW50IGRheSA9IDE7IGRheSA8PSBkYXlzX2luX21vbnRoOyBkYXkrKykgewogICAgICAgIHByaW50ZigiJTNkICIsIGRheSk7CiAgICAgICAgLy8g4LiW4LmJ4Liy4LiE4Lij4LiaIDcg4Lin4Lix4LiZ4LmD4Lir4LmJ4LiC4Li24LmJ4LiZ4Lia4Lij4Lij4LiX4Lix4LiU4LmD4Lir4Lih4LmICiAgICAgICAgaWYgKChkYXkgKyBmaXJzdF9kYXkgLSAxKSAlIDcgPT0gMCkgewogICAgICAgICAgICBwcmludGYoIlxuIik7CiAgICAgICAgfQogICAgfQoKICAgIHJldHVybiAwOwp9