A niven number is a non-negative number that is divisible by the sum of its digits.
Write a function/method named niven
which prints all the niven numbers from 0 to 100 inclusive, each on their own line. The function needs to compute the solution, i.e., it is not acceptable to use any pre-computed data structure or solution.
Source: https://code-golf.io/niven-numbers
niven←⍸0=⍳|⍨1⊥10⊥⍣¯1⍳
You can read about this here or try it online.
niven←⍪{⍵/⍨0=⍵|⍨{+/⍎¨⍕⍵}¨⍵}⍳100
niven=_=>{for(n=0;n<101;n++)n%(n/10+n%10|0)||print(n)}
def niven():[print(n)for n in range(1,101)if n%(n//10+n%10)<1]
niven=[x|x<-[1..100],x`mod`(sum(map(\x->read[x]::Int)(show x)))<1]
def niven():[print(i)for i in range(1,101)if not i%sum(map(int,str(i)))]
def niven():[print(i)for i in range(1,101)if i%sum([*map(int,str(i))])<1]