BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//American Young Coder - ECPv6.10.1.1//NONSGML v1.0//EN
CALSCALE:GREGORIAN
METHOD:PUBLISH
X-ORIGINAL-URL:https://www.ayclogic.com
X-WR-CALDESC:Events for American Young Coder
REFRESH-INTERVAL;VALUE=DURATION:PT1H
X-Robots-Tag:noindex
X-PUBLISHED-TTL:PT1H
BEGIN:VTIMEZONE
TZID:America/Los_Angeles
BEGIN:DAYLIGHT
TZOFFSETFROM:-0800
TZOFFSETTO:-0700
TZNAME:PDT
DTSTART:20250309T100000
END:DAYLIGHT
BEGIN:STANDARD
TZOFFSETFROM:-0700
TZOFFSETTO:-0800
TZNAME:PST
DTSTART:20251102T090000
END:STANDARD
END:VTIMEZONE
BEGIN:VEVENT
DTSTART;TZID=America/Los_Angeles:20251016T190000
DTEND;TZID=America/Los_Angeles:20251016T200000
DTSTAMP:20260429T232542
CREATED:20251017T080355Z
LAST-MODIFIED:20251017T080355Z
UID:31334-1760641200-1760644800@www.ayclogic.com
SUMMARY:7 PM – USACO Bronze – Darin
DESCRIPTION:What We Did Today:\n\nWent through the Farmer John Actually Farms problem for the brute force\n\nHomework:\nImplement the brute force code for the problem: https://usaco.org/index.php?page=viewproblem2&cpid=1349 \nBrute-Force Approach\nWhen we want to check impossibility\, the discussed method in class of comparing pairwise growths only works for whether or not it can stay in the desired positioning forever. \nInstead\, we can only check impossibility by checking each “point” that is a candidate for a successful ordering. \n\n\nEnumerate “interesting” daysCollect a finite set of days to test: \n\n\nDay 0 (ordering could be right from the start) \n\n\nFor every integer day d≥0 where two plants would be equal height\, take the day after it as d+1 (a correct ordering only happens when a switch happens)\nHint: You can think of each plant’s growth as a line that grows in the xy plane\, so what is a formula used to find the point of intersection between two lines (in other words\, find the day the plants have the same height) ? \n\n\n\n\nSimulate heights on each candidate dayFor each candidate day d\, compute the heights of every plant (think what formula works for this) \n\n\nCount “strictly taller” and compare to targetFor each plant i\, count how many plants have height strictly greater than Hi(d).If all counts match the given target array t\, record the day d. \n\n\nAnswerOutput the smallest candidate day that works\, or −1 if none do. \n\n\nEdge cases: \n\nSanity check pairsFor each pair of plants (i\,j)\, note whether their relative order could ever change: if they grow at the same rate and start equal\, they’ll be tied forever (makes a strict ranking impossible).\n\nNotes:\nYou can reach out to me at ddjapri@ayclogic.com if you have any questions! \nYou can find class notes here.
URL:https://www.ayclogic.com/event/7-pm-usaco-bronze-darin/
CATEGORIES:Intro To Competitive,Java
END:VEVENT
END:VCALENDAR