Environmental Sciences, asked by technews326, 1 month ago

In mathematics, a Harshad number (or Niven number) in a given number base is an integer that is
divisible by the sum of its digits when written in that base. Harshad numbers in base n are also
known as n-Harshad (or n-Niven) numbers. Below are the first few Harshad Numbers represented in
base 10: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 18, 20……… Given a number in base 10, our task is to check
if it is a Harshad Number or not. Draw a flowchart to accept any number and display whether it is a
Harshad Number.

Answers

Answered by zunairahshaikh5
0

Answer:

An integer number in base 10 which is divisible by the sum of its digits is said to be a Harshad Number.

Explanation:

Answered by mindfulmaisel
0

Harshad Number

As given in the question, a Harshad or Niven number is any integer which is divisible by the sum of its digits when written in that base.

Examples of Harshad numbers with base 10 are 1,2,3,4,10,12,18, etc.

Flowchart:

1. Accept any number/integer.

2. Find the sum of its digits.

3. Check whether the number/integer gives the remainder 0 when divided by the sum of its digits.

4. If the remainder is 0, it is a Harshad number, otherwise it is not a Harshad number.

Similar questions