An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

The constraints on 48 non-negative integers that sum to at most 65536 force some values to be relatively rare.

(and I think I mis counted, if the sum can be <= 65536 then number is between 32768 and 65535 can occur at most 2 times, number is between 16384 and 32767 can occur at most 4 times, etc. also, if one of the numbers can be 65536, not going over none above 65536, then we need to be able to represtnt one mre value.

perhaps we could add something like

0 -> number is between 0 and 2047, 1 + 11 bits

10 -> number is between 2048 and 4095, 2 + 11 bits, happens at most 32 times

110 -> number is between 4096 and 8191, 3+12 bits, happens at most 16 times

1110 -> number is between 8192 and 16383, 4+13 bits, happens at most 8 times

11110 -> number is between 16384 and 32767, 5+14 bits, happens at most 4 times

11111 -> number is between 32768 and 65535, 5+15 bits, happens at most 2 times (but the 0 after the 11111 was not necessary)

11111 000000000000000 -> 32768

...

11111 111111111111110 -> 65534 at most 1 time 5+15 bits

11111 111111111111111 0 -> 65535 at most 1 time 5+15+1 bits

11111 111111111111111 1 -> 65536 at most 1 time 5+15+1 bits

)

so we would actually do better to use more bits for larger values, if that allowed us to use fewer bits for the more common values.

But it would be hard to get below 1+11 bits for the potentially most comon range uness we go to representations that allow fractional bits per number.

Which is doable, but may not be worth it.