Computer Science, asked by abbassayed80095, 6 months ago


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 freedarajesh2003
0

Answer:

Explanation:

Jun 6, 2018 — A class Number has been defined to find the frequency of each digit present in it and the sum of the digit and ... Some of the members of the class Number are given below: Class name: Number Data member: num: integer variable to store the number. ... int sum(): to return the sum of the digits of the number.

Similar questions