выражение должно иметь тип класса, но имеет тип "std::vector<int, std::allocator<int>> (*)(int lng, int wdth)"C/C++(153)
#include <vector>
class SqInRect
{
public:
int length;
int width;
int square_figure;
static std::vector<int> sqInRect(int lng, int wdth);
SqInRect(){
length = sqInRect.size();//Здесь
width = sqInRect.at(0);//Здесь
square_figure = length * width;
}
void Square(int square_figure, int increment_figure){
if(square_figure % increment_figure * increment_figure >= increment_figure * increment_figure){
square_figure -= increment_figure * increment_figure;
sqInRect.push_back(increment_figure);//и здесь подчеркивает.
}else{
increment_figure--;
}
if(square_figure != 0)
Square(square_figure, increment_figure);
}
};