Wiktionary talk:Main Page/interesting

From Wiktionary, the free dictionary
Jump to navigation Jump to search

Documentation[edit]

Designation of Week[edit]

Many features in Interesting Stuff will be stable and therefore presented on a specific weekday, possibly Friday's Foreign Phrase for instance. In order to provide some flexibility, less certain content can be alternated from week to week. This is done by designating weeks as A, B, or C as follows: Weeks alternate between A and B, except for the first 7 days at the beginning of the month which interrupt this cycle with the designation C. The calendar below illustrates the resulting pattern.

Each week is also assigned a number to uniquely identify it. For instance, weeks designated as C are assigned the numerical month. There is only one C3 Tuesday, and there is always one C3 Tuesday, just to pick a random example, namely the first Tuesday of March. Weeks designated A and B run Monday through Sunday (apart from partial weeks like B0) though they can be interrupted at month boundaries. There are always at least 20 weeks designated A, and likewise for B. There is exactly one A3 Tuesday, to pick another example, and exactly one B19 Friday. Although year boundaries complicate the situation per ISO 8601, these can be adjusted as desired.

Calendar[edit]

2009 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Jan C1 C1 C1 C1 C1 C1 C1 B0 B0 B0 B0 A1 A1 A1 A1 A1 A1 A1 B1 B1 B1 B1 B1 B1 B1 A2 A2 A2 A2 A2 A2
Feb C2 C2 C2 C2 C2 C2 C2 A2 B2 B2 B2 B2 B2 B2 B2 A3 A3 A3 A3 A3 A3 A3 B3 B3 B3 B3 B3 B3
Mar C3 C3 C3 C3 C3 C3 C3 B3 A4 A4 A4 A4 A4 A4 A4 B4 B4 B4 B4 B4 B4 B4 A5 A5 A5 A5 A5 A5 A5 B5 B5
Apr C4 C4 C4 C4 C4 C4 C4 B5 B5 B5 B5 B5 A6 A6 A6 A6 A6 A6 A6 B6 B6 B6 B6 B6 B6 B6 A7 A7 A7 A7
May C5 C5 C5 C5 C5 C5 C5 A7 A7 A7 B7 B7 B7 B7 B7 B7 B7 A8 A8 A8 A8 A8 A8 A8 B8 B8 B8 B8 B8 B8 B8
Jun C6 C6 C6 C6 C6 C6 C6 A9 A9 A9 A9 A9 A9 A9 B9 B9 B9 B9 B9 B9 B9 A10 A10 A10 A10 A10 A10 A10 B10 B10
Jul C7 C7 C7 C7 C7 C7 C7 B10 B10 B10 B10 B10 A11 A11 A11 A11 A11 A11 A11 B11 B11 B11 B11 B11 B11 B11 A12 A12 A12 A12 A12
Aug C8 C8 C8 C8 C8 C8 C8 A12 A12 B12 B12 B12 B12 B12 B12 B12 A13 A13 A13 A13 A13 A13 A13 B13 B13 B13 B13 B13 B13 B13 A14
Sep C9 C9 C9 C9 C9 C9 C9 A14 A14 A14 A14 A14 A14 B14 B14 B14 B14 B14 B14 B14 A15 A15 A15 A15 A15 A15 A15 B15 B15 B15
Oct C10 C10 C10 C10 C10 C10 C10 B15 B15 B15 B15 A16 A16 A16 A16 A16 A16 A16 B16 B16 B16 B16 B16 B16 B16 A17 A17 A17 A17 A17 A17
Nov C11 C11 C11 C11 C11 C11 C11 A17 B17 B17 B17 B17 B17 B17 B17 A18 A18 A18 A18 A18 A18 A18 B18 B18 B18 B18 B18 B18 B18 A19
Dec C12 C12 C12 C12 C12 C12 C12 A19 A19 A19 A19 A19 A19 B19 B19 B19 B19 B19 B19 B19 A20 A20 A20 A20 A20 A20 A20 B20 B20 B20 B20

There are days of the year that are designated C, or about 23%. The remaining days are divided more or less evenly between A and B, although slightly favored toward the starting designation B (39% to 38%).

Consider a single weekday such as Thursdays. A stable feature will be presented 100% of the time, on any designated day A, B, or C. If a feature is to be displayed just at the beginning of the month with C and a more certain feature with the combination of A and B, their ratios will be about 23% to 77%. A feature selected for B would show 39% of the time versus A and C together at 61%.

Code[edit]

Today's date of April 26 is listed above as B6 Friday. From the main page —and only from there— the week designation is determined by the following code:

{{#ifexpr:{{CURRENTDAY}}>7|{{#ifexpr:({{CURRENTWEEK}}-{{CURRENTMONTH}}-1)mod2|A|B}}|C}}

The weekday (7 for Sunday) and week designation (A, B, or C) are used to select a feature for the current day, as determined by Wiktionary:Main Page/interesting. Because the features are archived and cycled over the year, as with Word of the Day, the week number determined by:

{{#ifexpr:{{CURRENTDAY}}>7|{{#expr:ceil(({{CURRENTWEEK}}-{{CURRENTMONTH}}-1)/2)}}|{{#expr:{{CURRENTMONTH}}}}}}

provides the specific article, for instance phrasebook/B5 or phrasebook/B19 or similar. Note that the offset of -1 italicized in both samples above can be adjusted to make the year start and end on the desired week designation.

Comments[edit]