A class called DigiNumber has been defined to find the frequency of each digit present in a
number and the sum of the digits. Some of the members of the class Digi Number are given below
[C
Class name
DigiNumber
Data members / Instance variables
NUM
long integer type
Member functions / Methods
Digi Numbero
constructor to assign 0 to num
Die Number(long n)
constructor to assign n to num.
void digitfrequancy
find the frequency of each digit present in num and to display it.
long sumDigits (long N) i to return the sum of the digits of the number stored in num.
void printsumo
print sum of digits of num by invoking recursive function
Specify the class DigiNumber giving the details of two constructors and functions void digitfrequencyo,
long sumDigits(long N) and void printsumo
Answers
Answered by
0
Answer:
.....................................
Similar questions
Math,
3 months ago
Art,
3 months ago
English,
3 months ago
English,
6 months ago
Computer Science,
6 months ago
Accountancy,
11 months ago
Geography,
11 months ago