In this question I don’t get how they arrive at the k values and the integral boundaries
The given potential repeats itself every 2a, instead of a. Therefore the period of one oscillation is \frac{2 \pi}{2a}, instead of \frac{2 \pi}{a}. Consequently the first avoided crossing happens at the BZ boundary which in this case is: \frac{\pi}{2a}.
The band gap between the first and the second band is determined by the first Fourier component (the boundaries: \frac{\pi}{2a} and \frac{-\pi}{2a} come from the fact that the period of this problem differs, as stated earlier, from ‘usual’ problems given in the lecture notes). The band gap between the second and third gap is determined by the second Fourier component, which is again adjusted due to the different period.
Note that it is also important to change the boundaries of integration, and the normalising pre factor due to the different period.