"get_rectangle_count_by_side" function add.