Harshad Number Calculator

Input a number to check if it's a Harshad number, or input a range to generate all Harshad numbers within it.

Harshad Number Check or Generate

What is a Harshad Number?

A Harshad number, also known as a Niven number, is an integer that is divisible by the sum of its digits. For example, the number \( 18 \) has a digit sum of \( 1 + 8 = 9 \). Since \( 18 \) is divisible by \( 9 \), it is a Harshad number.

How to Determine if a Number is a Harshad Number

  1. Calculate the digit sum: Add up all the digits of the number.
  2. Check divisibility: Verify if the original number is divisible by its digit sum. If it is divisible, the number is a Harshad number; otherwise, it is not.

Examples

Example 1: Is 54 a Harshad Number?

Solution:

Digit sum: \(5 + 4 = 9\).

Divisibility: \(54 \div 9 = 6\) (divisible).

Result: \( 54 \) is a Harshad number.

Example 2: Is 119 a Harshad Number?

Solution:

Digit sum: \(1 + 1 + 9 = 11\).

Divisibility: \(119 \div 11 = 10.8\) (not divisible).

Result: \( 119 \) is not a Harshad number.

Example 3: Is 2025 a Harshad Number?

Solution:

Digit sum: \(2 + 0 + 2 + 5 = 9\).

Divisibility: \(2025 \div 9 = 225\) (divisible).

Result: \( 2025 \) is a Harshad number.

The First 100 Harshad Numbers

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 12
  • 18
  • 20
  • 21
  • 24
  • 27
  • 30
  • 36
  • 40
  • 42
  • 45
  • 48
  • 50
  • 54
  • 60
  • 63
  • 70
  • 72
  • 80
  • 81
  • 84
  • 90
  • 100
  • 102
  • 108
  • 110
  • 111
  • 112
  • 114
  • 117
  • 120
  • 126
  • 132
  • 133
  • 135
  • 140
  • 144
  • 150
  • 152
  • 153
  • 156
  • 162
  • 171
  • 180
  • 190
  • 192
  • 195
  • 198
  • 200
  • 201
  • 204
  • 207
  • 209
  • 210
  • 216
  • 220
  • 222
  • 224
  • 225
  • 228
  • 230
  • 234
  • 240
  • 243
  • 247
  • 252
  • 261
  • 264
  • 266
  • 270
  • 280
  • 285
  • 288
  • 300
  • 306
  • 308
  • 312
  • 315
  • 320
  • 322
  • 324
  • 330
  • 333
  • 336
  • 342
  • 351
  • 360
  • 364
  • 370
  • 372