routesum is both a command-line program and a Golang library that performs route summarization on a list of IP addresses and CIDR-formatted networks. Route summarization is the process of reducing a list of IPs and networks to its shortest possible form.
netmask is a CLI tool for converting different types of network representations
Convert some IP ranges into CIDR ranges and then summarise those ranges into the shortest possible form:
netmask -c 10.237.0.0:10.255.255.255 10.0.0.0:10.235.255.255 | routesum