This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A327846 #20 Mar 08 2020 23:25:54 %S A327846 30,29,28,27,26,25,24,23,22,21,20,19,18,17,16,15,14,13,12,11,10,9,8,7, %T A327846 6,5,4,3,2,1,0,27,26,25,24,23,22,21,20,19,18,17,16,15,14,13,12,11,10, %U A327846 9,8,7,6,5,4,3,2,1,0,30,29,28,27,26,25,24,23,22,21,20,19,18,17,16,15,14,13,12,11,10,9,8,7,6 %N A327846 Full days remaining in the month on the Gregorian calendar starting at n-th day of a non-leap year. %H A327846 Jinyuan Wang, <a href="/A327846/b327846.txt">Table of n, a(n) for n = 1..365</a> %e A327846 On March 27th, the 86th day of the year where n=86, there are 4 full days left in the month of March, a(86)=4. %t A327846 Array[Range[# - 1, 0, -1] &@ Which[MemberQ[{4, 6, 9, 11}, #], 30, # == 2, 28, True, 31] &, 12] // Flatten (* _Michael De Vlieger_, Sep 30 2019 *) %o A327846 (C++) %o A327846 #include <iostream> %o A327846 using namespace std; %o A327846 int main(){ %o A327846 int m=1; %o A327846 for(int d=30;m<=12;d--){ %o A327846 cout<<d<<","; %o A327846 if(d==0){ %o A327846 m++; %o A327846 if(m==4||m==6||m==9||m==11) %o A327846 d=30; %o A327846 else if(m==2) %o A327846 d=28; %o A327846 else %o A327846 d=31; %o A327846 } %o A327846 } %o A327846 } %Y A327846 Cf. A061251, A073304. %K A327846 nonn,fini,full %O A327846 1,1 %A A327846 _Andrew Pham_, Sep 27 2019