This paper addresses the optimization of CNC (Computer Numerical Control) working time through the strategic positioning and grouping of cutting tools. Our analysis primarily focused on evaluating the previous arrangement of tools in the magazine and exploring the potential for repositioning them to enhance CNC operational efficiency. The work methodology is based on the collection of direct data from CNC as well as through CAD/CAM simulations. The collected data are analyzed with the Python programming language, which is one of the most used and efficient languages now. By grouping the tools according to the same function, tools were repositioned next to each other, which we obtained. After collecting the data and processing them in the Python programming language, we made a visualization of the data. Working time is reduced from 27.44 s to 26.46 s and results are analyzed in the Python Programming language. The working time is reduced by 0.98 s, which is approximately a 3.57% reduction in the working time. This indicates a significant improvement in efficiency due to the optimization of the cutting tool positions in the magazine.