Define a class named Number with the following
description:
Instance variables/ data members:
int num - to store a number
Member methods:
Number() - default constructor to initialize num by 0
void accept() - to input and store an integer in num
boolean issquare(int x) - to check whether the value in x is a
square of the value in num and return true if it is and false otherwise.
Write a main method to create an object of the class and call
the above member methods to print the appropriate
Answers
Answered by
2
Answer:
hnzjznjshsnuxhndubsizusb d x
Similar questions
Math,
3 months ago
Social Sciences,
3 months ago
History,
3 months ago
Computer Science,
6 months ago
Math,
6 months ago
English,
10 months ago
English,
10 months ago