IP Address overlapping/in range of CIDR
I have an IP address in unsigned long format, coding in C++ I have a CIDR notation IP address range such as "10.2.3.98/24"
How do i check if my IP address overlaps with the mentioned range?