The easiest way to accept two parameters of an option is to join them with a non-blank character like ':'
:
myprogram -a min:max other-options
This way getopt
thinks of it as of a single parameter. When you handle it you need to separate it in two yourself. If both halves are numbers, then this should work:
if (sscanf(optarg, "%d:%d", &min, &max) != 2)
/* report an error */