Accurate detection of spectrum holes is the most important and critical task in any cognitive radio (CR) communication system. When a single spectrum sensor is assigned to detect a specific primary channel, then the detection may be unreliable because of noise, random multipath fading and shadowing. Also, even when the primary channel is invisible at the CR transmitter, it may be visible at the CR receiver (the hidden primary channel problem). With a single sensor per channel, a high and consistently uniform level of sensitivity is required for reliable detection. These problems are solved by deploying multiple heterogeneous sensors at distributed locations. The proposed spectrum hole detection method uses cooperative sensing, where the challenge is to properly assign sensors to different primary channels in order to achieve the best reliability, a minimum error rate and high efficiency. Existing methods use particle swarm optimization, the ant colony system, the binary firefly algorithm, genetic algorithms and non-linear mixed integer programming. These methods are complex and require substantial pre-processing. The aim of this paper is to provide a simpler solution by using simpler binary integer programming for optimal assignment. Optimal assignment minimizes the probability of interference which is a non-linear function of decision variables. We present an approach used to linearize the objective function. Since multiple spectrum sensors are used, the optimal constrained assignment minimizes the maximum of interferences. While performing the optimization, the proposed method also takes care of the topological layout concerned with channel accessibility. The proposed algorithm is easily scalable and flexible enough to adapt to different practical scenarios.