There is a task to determine the type of a shape (square or circle) in the matrix. The matrix is written into a text file in the form of 15 lines of 15 characters each, the diameter of a circle or the side of a square can be from 5 to 10 characters inclusive:
000000000000000 000111111000000 000111111000000 000111111000000 000111111000000 000111111000000 000111111000000 000000000000000 000000000000000 000000000000000 000000000000000 000000000000000 000000000000000 000000000000000 000000000000000 Please tell me if there are any methods for determining such figures. I want to do the implementation myself, I just don’t want to reinvent the wheel. I plan to write on C++ under Windows , with a minimum of third-party libraries.