Method for fitting printed circuit boards by means of fitting lines of a fitting system for fitting the printed circuit boards (205, 215) with electronic components, the method comprising the following steps: - detecting requirements for fitting a plurality of printed circuit boards (110, 205, 215) with components to be respectively fitted, - a requirement defining a printed circuit board and the components to be fitted thereon; - determining a set of printed circuit boards, the component variances of which exceed a predetermined amount, - a component variance of a printed circuit board respectively representing the number of different components to be fitted on a printed circuit board (110, 205, 215); - determining printed circuit boards (110, 205, 215) from the set which in pairs require highly different sets (225, 230) of components, - allocating the printed circuit boards (110, 205, 215) from the set to the fitting lines by means of integer linear programming in such a manner that the determined printed circuit boards (110, 205, 215) are allocated to fitting lines which are as different as possible and the sum of component variances of the fitting lines is minimized as far as possible, - the component variance of a fitting line representing the number of different component types used on the fitting line; - the integer linear program comprising a determination of a starting allocation of printed circuit boards (110, 205, 215) to fitting lines as the current allocation and an allocation of printed circuit boards (110, 205, 215) in the set to the fitting lines based on the current allocation by means of an optimization program by means of integer linear programming, and - fitting the printed circuit boards with components on the respectively allocated fitting lines. - detecting requirements for fitting a plurality of printed circuit boards (110, 205, 215) with components to be respectively fitted, - a requirement defining a printed circuit board and the components to be fitted thereon; - determining a set of printed circuit boards, the component variances of which exceed a predetermined amount, - a component variance of a printed circuit board respectively representing the number of different components to be fitted on a printed circuit board (110, 205, 215); - determining printed circuit boards (110, 205, 215) from the set which in pairs require highly different sets (225, 230) of components, - allocating the printed circuit boards (110, 205, 215) from the set to the fitting lines by means of integer linear programming in such a manner that the determined printed circuit boards (110, 205, 215) are allocated to fitting lines which are as different as possible and the sum of component variances of the fitting lines is minimized as far as possible, - the component variance of a fitting line representing the number of different component types used on the fitting line; - the integer linear program comprising a determination of a starting allocation of printed circuit boards (110, 205, 215) to fitting lines as the current allocation and an allocation of printed circuit boards (110, 205, 215) in the set to the fitting lines based on the current allocation by means of an optimization program by means of integer linear programming, and - fitting the printed circuit boards with components on the respectively allocated fitting lines.