Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Which is incorrect? The keyword static is used in a static function declaration

ID: 3782266 • Letter: W

Question

Which is incorrect? The keyword static is used in a static function declaration in a class but not m the function definition. It is legal to call a constructor as a member function of an object of a class, as in class A {public: A(){} A(int x, int y):xx(x), yy(y) {}//other members private; int xx; int yy.}; int main() {A w. w.A(2, 3);//is this legal? A class may have another class typo object as a member A constructor can be called implicitly. (Implicitly means the compiler did it for you.) Example: A x = A();//explicitly A x(2);//implicitly

Explanation / Answer

The first one is not clear (i mean the question is incomplete)

2) The keyword static is used in a static function declaration in a class but not in the function definition .

this answer is incorrect for the question which is given below

it is used mainly for memory management purpose only we can apply java static keyword

with variables,blocks,methods etc.