From charlesreid1

Problem Description

This problem is an ICPC programming competition problem.

In this problem, we have a race track of width x = 0 to x = w, height y = 0 to y = h. We have a character that begins at the x-axis (y=0) and moves toward the finish line (y=h) with a steady velocity v.

You control the character's horizontal velocity, -v/r to +v/r, and your goal is to obtain as many gems as possible.

The location of gems are given by (x,y) integer pairs on the grid. Determine the maximum number of gems that can be obtained by the character.

Git repo has solution explanation: https://git.charlesreid1.com/cs/java/src/master/dynamic-programming/racing-gems

Flags