Your mission
Return the first second at which the sway climbs above the limit.
today's brief
London, June 10 2000. The Millennium Bridge opens and about two thousand people walk on. The deck starts swinging sideways. Walkers spread their feet to stay upright, which pushes in time with the swing, which makes the swing bigger. It shut after two days and reopened nearly two years later, with 37 dampers bolted underneath.
See it in action
first_wobble({2,2,2,2}, 4, 5)2first_wobble({-2,-2,-2}, 3, 0)-1first_wobble({97}, 1, 5)0
Your checklist
Constraints
- Expected file
bridge.c- Allowed functions
- None. Write every helper yourself.
