TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(input())
sum_a = 0
for i in range(n):
  a = n[i]
  sum_a += a
if n % sum_a == 0:
  print('Yes')
else:
  print('No')


n = str(input())
l = []
for i in range(n):
  a = n[i]
  l.append(a)
sum_l = sum(l)
if int(n) % sum_l == 0:
  print('Yes')
else:
  print('No')

n = int(input())
l = []
for i in range(n):
  a = n[i]
  sum_a += a
if n % sum_a == 0:
  print('Yes')
else:
  print('No')


n = str(input())
l = []
for i in range():
  a = n[i]
  l.append(a)
sum_l = sum(l)
if int(n) % sum_l == 0:
  print('Yes')
else:
  print('No')

N = input()
ans = 0
for i in N:
    ans += int(i)
if int(N)%ans == 0:
    print('Yes')
else:
    print('No') 


Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
S = input()
Slist = list(S)
res = 0
for i in Slist:
  res += int(i)
print(int(S) % res = 0)

S = int(input())
Slist = list(str(S))
res = 0
for i in Slist:
  res += int(i)
if S % res == 0:
  print("yes")
else:
  print("no")

S = input()
Slist = list(S)
res = 0
for i in Slist:
  res += int(i)
print(int(S) % res == 0)

S = int(input())
Slist = list(str(S))
res = 0
for i in Slist:
  res += int(i)
print(S % res == 0)

S = int(input())
Slist = list(str(S))
res = 0
for i in Slist:
  res += int(i)
if S % res == 0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(input())
sum = 0
tmp = n

while tmp > 0:
    sum += tmp % 10
    tmp /= 10

if n % sum == 0:
    print("Yes")
else:
    print("No")



n = int(input())
sum = 0
tmp = n

while tmp > 0:
    sum += tmp % 10
    tmp //= 10

if n % sum == 0:
    print("Yes")
else:
    print("No")



Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()
S = 0
for i in range(len(N)):
    S += int(N[i])
if N % S == 0:
    print('Yes')
else:
    print('No')


N = input()
S = 0
for i in range(len(N)):
    S += int(N[i])
if int(N) % S == 0:
    print('Yes')
else:
    print('No')

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
s=list(input())
n=int(s)
if n%(sum(s))==0:
  print('Yes')
else:
  print('No')

i=input()
s=list(map(int,i))
n=int(i)

if n%(sum(s))==0:
  print('Yes')
else:
  print('No')

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = int(input())
sum = 0

while N > 0:
    sum += N % 10
    N = N // 10

if sum % N == 0:
    print('Yes')
else:
    print('No')

n = str(input()); print("Yes" if int(n) % sum([int(n[i]) for i in range(len(n))]) == 0 else "No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = input()
sum = sum(list(map(int, n)))
if n % sum == 0:
  print("Yes")
else:
  print("No")

n = int(input())
sum = sum(list(map(int, str(n))))
if n % sum == 0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N=input()
sn = 0
for n in N:
    sn += int(n)

if N % sn == 0:
    print('Yes')
else:
    print('No')

N=input()
sn = 0
for n in N:
    sn += int(n)

if int(N) % sn == 0:
    print('Yes')
else:
    print('No')

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(input())
s = 0
tmp = n
while tmp:
  s += tmp % 10
  tmp // 10
if n % s == 0:
  print('Yes')
else:
  print('No')

str_n = input()
n = int(str_n)
s = 0
for digit in str_n:
  s += int(digit)
if n % s == 0:
  print('Yes')
else:
  print('No')

Verdicts: Time Limit Exceeded

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
def solve (N):
    s=0
    for b in str(N):
        s = s + int(b)
    if N % s ==0:
        return 'Yes'
    else:
        return 'No'


import sys

def solve (N):
    s=0
    for b in str(N):
        s = s + int(b)
    if N % s ==0:
        return 'Yes'
    else:
        return 'No'


def solve(n):
   

def readQuestion():
    line = sys.stdin.readline().rstrip()
    return int(line)

def main():
    n = readQuestion()
    answer = solve(n)
    print(answer)
    
if __name__ == '__main__':
    main()

import sys


def solve (N):
    s=0
    for b in str(N):

        s = s + int(b)
    if N % s ==0:
        return 'Yes'
    else:
        return 'No'
   


def readQuestion():
    line = sys.stdin.readline().rstrip()
    return int(line)

def main():
    n = readQuestion()
    answer = solve(n)
    print(answer)
    
if __name__ == '__main__':
    main()

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
#coding: utf-8

N = str(input())
sum = 0

for i in range(len(S)):
    sum += int(N[i])

if(int(N)%sum==0):
    print('Yes')
else:
    print('No')

#coding: utf-8

N = str(input())
sum = 0

for i in range(len(N)):
    sum += int(N[i])

if(int(N)%sum==0):
    print('Yes')
else:
    print('No')

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
import math
i = input()
a = i.split()
a = int(a[0])
b = a
s = 0
for i in range(len(i)):
    s = s + (a % 10)
    a = math.floor(a / 10)

ans = b % s
print(s)
print(ans)

if (b % s == 0):
    print("Yes")
else:
    print("No")


import math
i = input()
a = i.split()
a = int(a[0])
b = a
s = 0
for i in range(len(i)):
    s = s + (a % 10)
    a = math.floor(a / 10)

ans = b % s


if (ans == 0):
    print("Yes")
else:
    print("No")




Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
import math

n = int(input())
n_check = n
num = []
for i in range(int(math.log10(n)+1)+1):
    print(num, n)
    num.append(n % 10)
    n /= 10
if n_check%int(sum(num)) == 0:
    ans = 'Yes'
else:
    ans = 'No'
print(ans)

import math

n = int(input())
n_check = n
num = []
for i in range(int(math.log10(n)+1)+1):
    num.append(n % 10)
    n /= 10
    n -= num[i]/10
if n_check%int(sum(num)) == 0:
    ans = 'Yes'
else:
    ans = 'No'
print(ans)


Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
s = int(input())

sm = sum([int(c) for c in s])
if s%sm == 0:
  print("Yes")
else:
  print("No")

s = int(input())

sm = sum([int(c) for c in str(s)])
if s%sm == 0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
s = input()
n = int(s)
sn = 0
for c in s:
  sn += int(c)
if n % sn:
  print('Yes')
else:
  print('No')


s = input()
n = int(s)
sn = 0
for c in s:
  sn += int(c)
if n % sn == 0:
  print('Yes')
else:
  print('No')


Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
i = 0
wa = 0
while i < len(str(N)):
    wa = wa + int(str(N)[i:i+1])
    i += 1
if N % wa == 0:
    print("Yes")
elif N % wa != 0:
    print("No")

i = 0
wa = 0
while i len(str(N)):
  wa = wa + int(str(N)[i:i+1])
  i += 1
if N % wa == 0:
  print("Yes")
elif N % wa != 0:
  print("No")

from sys import stdin
N = int(stdin.readline().rstrip())
i = 0
wa = 0
while i < len(str(N)):
    wa = wa + int(str(N)[i:i+1])
    i += 1
if N % wa == 0:
    print("Yes")
elif N % wa != 0:
    print("No")

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = int(input())

SN = N % 10
for i in range(10):
	n = N
	SN += n // 10**(9 - i)
	n = n % 10**(9 - i)

if N % SN == 0:
	print('Yes')
else:
	print('No')

N = int(input())

SN = N % 10
for i in range(1, 10):
	n = N
	SN += n // 10**(9 - i)
	n = n % 10**(9 - i)

if N % SN == 0:
	print('Yes')
else:
	print('No')

N = int(input())

SN = 0
n = N
for i in range(10):
	SN += n // 10**(9 - i)
	n = n % 10**(9 - i)

if N % SN == 0:
	print('Yes')
else:
	print('No')

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n=int(input())
s=0
if 1<=n<10:
  print("Yes")
  exit()
else:
  while n>10:
    s+=n%10
    n//=10
  if n%s==0:
    print("Yes")
    exit()

print("No")

n=str(input())
s=0
for i in range(len(n)):
  s+=int(n[i])

n=int(n)
if n%s==0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N=input()
numlist=list(N)
numsum=0
for num in numlist:
    numsum+=int(num)
if numsum%int(N)==0:
    print('Yes')
else:
    print('No')

N=input()
numlist=list(N)
numsum=0
for num in numlist:
    numsum+=int(num)
if int(N)%numsum==0:
    print('Yes')
else:
    print('No')

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = int(input())
L = [int(x) for x in str(N)]
print(sum(L))

N = int(input())
L = [int(x) for x in str(N)]
S = sum(L)
if N%S == 0:
    print('Yes')
else:
    print('No')

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = input()

for i in range(len(n)):
    nsum += int(n[i])
    
if int(n) % nsum == 0:
    print("Yes")
else:
    print("No")

n = input()

nsum = 0
for i in range(len(n)):
    nsum += int(n[i])

if int(n) % nsum == 0:
    print("Yes")
else:
    print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
from a import resolve

import sys
from io import StringIO
import unittest

class TestClass(unittest.TestCase):
    def assertIO(self, input, output):
        stdout, stdin = sys.stdout, sys.stdin
        sys.stdout, sys.stdin = StringIO(), StringIO(input)
        resolve()
        sys.stdout.seek(0)
        out = sys.stdout.read()[:-1]
        sys.stdout, sys.stdin = stdout, stdin
        self.assertEqual(out, output)
    def test_入力例_1(self):
        input = """12"""
        output = """Yes"""
        self.assertIO(input, output)
    def test_入力例_2(self):
        input = """101"""
        output = """No"""
        self.assertIO(input, output)
    def test_入力例_3(self):
        input = """999999999"""
        output = """Yes"""
        self.assertIO(input, output)

if __name__ == "__main__":
    unittest.main()


import sys

def resolve():
  n = int(input())
  s = str(n)
  sum = 0
  for c in s:
    sum += int(c)
  if n % sum == 0:
    print("Yes")
  else:
    print("No")
  return

if __name__ == "__main__":
  resolve()


Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
print(sum(map(int, input())))


N = int(input())
print('Yes' if N % sum(map(int, str(N))) == 0 else "No")


Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n=int(input())
num=n
sn=0
while(n>=10):
  sn=sn+n%10
  n=n/10
sn=sn+n

if num%sn==0:
  print("Yes")
else:
  print("No")

n=int(input())
num=n
sn=0
while(n>=10):
  sn=sn+n%10
  n=int(n/10)

sn=sn+n

if num%sn==0:
  print("Yes")
else:
  print("No")

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
def keta(x):
  wa = 0
  while x >= 0:
    wa = int(x % 10)
    x = x // 10
  return wa

n = int(input())
if n % keta(n) == 0:
  print("Yes")
else:
  print("No")
    

def keta(x):
  wa = 0
  while x >= 1:
    wa += int(x % 10)
    x = int(x / 10)
  return wa
 
n = int(input())
if n % keta(n) == 0:
  print("Yes")
else:
  print("No")

Verdicts: Time Limit Exceeded

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
import sys


def solve(a):
    s = 0
    for b in str(a):
        s += int(b)
    if a%s==0:
        return "Yes"
    else:
        return "No"
        

def readQuestion():
    line = sys.stdin.readline().rstrip()
    return line

def main():
    n = readQuestion()
    answer = solve(n)
    print(answer)
    
if __name__ == '__main__':
    main()

import sys


def solve(a):
    s = 0
    for b in str(a):
        s += int(b)
    if a%s==0:
        return "Yes"
    else:
        return "No"

def readQuestion():
    line = sys.stdin.readline().rstrip()
    return int(line)

def main():
    n = readQuestion()
    answer = solve(n)
    print(answer)
    
if __name__ == '__main__':
    main()

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
a=input()
l=[int(i) for i in list(str(a))]
s=0
for i in l:
  s+=i
if a % s==0:
  print("Yes")
else:
  print("No")

a=int(input())
l=[int(i) for i in list(str(a))]
s=0
for i in l:
  s+=i
if a % s==0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = list(input())
n = 0

S = 0
for i in range(len(N)):
    S = S + int(N[i])
    n = (int(N[i])999999999 * (10 ** (len(N) - i - 1))) + n
    
if n % S == 0:
    print('Yes')
else:
    print('No')

N = list(input())
n = 0

S = 0
for i in range(len(N)):
    S = S + int(N[i])
    n = (int(N[i])999999999 * (10 ** (len(N) - i - 1))) + n
    
if n % S == 0:
    print('Yes')
else:
    print('No')

N = list(input())
n = 0

S = 0
for i in range(len(N)):
    S = S + int(N[i])
    n = (int(N[i]) * (10 ** (len(N) - i - 1))) + n
    
if n % S == 0:
    print('Yes')
else:
    print('No')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(input())
s = sum(list(n))

if n % s == 0:
  print("Yes")
else:
  print("No")


n = int(input())
s = sum(map(int, list(str(n)))

if n % s == 0:
  print("Yes")
else:
  print("No")


n = int(input())
s = sum(map(int, list(str(n))))

if n % s:
  print("Yes")
else:
  print("No")


n = int(input())
s = sum(int(list(str(n))))

if n % s == 0:
  print("Yes")
else:
  print("No")


n = int(input())
s = sum(map(int,(list(str(n))))

if n % s == 0:
  print("Yes")
else:
  print("No")


n = int(input())
s = list(n)

if n % sum(s):
  print("Yes")
else:
  print("No")

n = int(input())
s = list(n)

if n % sum(s) == 0:
  print("Yes")
else:
  print("No")


n = int(input())
s = sum(map(int, list(str(n))))

if n % s == 0:
  print("Yes")
else:
  print("No")


Verdicts: Runtime Error

Runtime Error

Wrong Answer

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = input()
k = list(map(int, list(n)))
s = sum(n)
n = int(n)
if n%k:
  print("No")
else:
  print("Yes")

n = input()
k = list(map(int, list(n)))
s = sum(k)
n = int(n)
if n%s:
  print("No")
else:
  print("Yes")


Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(input())


sum = 0

for i in range(len(n)):
  sum += n[i]
  
if n % sum ==0:
  print("Yes")
else:
  print("No")

n = input()


sum = 0

for i in range(len(n)):
  sum += int(n[i])
  
if int(n) % sum ==0:
  print("Yes")
else:
  print("No")



Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = int(input())
if N%sum(list(map(int,list(str(a)))))==0:
  print("Yes")
else:
  print("No")


N = int(input())

if N%sum(map(int,str(N)))==0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
s = str(input())

    ans = 0

    for i in s:
        ans = ans + int(i)

    b = True if ans % 2 ==0 else False

    print(b)

if __name__ == "__main__":
    s = str(input())

    ans = 0

    for i in s:
        ans = ans + int(i)

    b = True if int(s) % ans == 0 else False

    print(b)

if __name__ == "__main__":
    s = str(input())

    ans = 0

    for i in s:
        ans = ans + int(i)

    b = True if ans % 2 == 0 else False

    print(b)

if __name__ == "__main__":
    s = str(input())

    ans = 0

    for i in s:
        ans = ans + int(i)

    b = True if ans % 2 == 0 else False

    print(b)

if __name__ == "__main__":
    s = str(input())

    ans = 0

    for i in s:
        ans = ans + int(i)

    b = "Yes" if int(s) % ans == 0 else "No"

    print(b)

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
S = input()
l = [int(x) for x in list(str(S))]
total = sum(l)
if int(S)%total==0:
    print('YES')
else:
    print('NO') 

S = input()
l = [int(x) for x in list(str(S))]
total = sum(l)
if int(S)%total==0:
    print('YES')
else:
    print('NO') 


N = int(input())
n = N
s = 0
while n> 0:
  s += n % 10
  n = n//10

if N % s == 0:
  print('Yes')
else:
  print('No')

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
s = input()
if s % sum(map(int, list(s))):
  print("No")
else:
  print("Yes")

s = input()
if int(s) % sum(map(int, list(s))):
  print("No")
else:
  print("Yes")


Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = input()

l = [int(i) for i in n]

if sum(l) % int(n) == 0:
  print('Yes')
else:
  print('No')

n = input()
 
l = [int(i) for i in n]
 
if int(n) % sum(l) == 0:
  print('Yes')
else:
  print('No')

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N=int(input())
n=list(str(N))
n=[int(n) for i in n]
summer=sum(n)
if N%summer==0:
  print("Yes")
else:
  print("No")

N=input()
wa=0
for i in N:
  wa+=int(i)
if (int(N)%wa)==0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
Nstr = input()
SN = 0
for i in N:
    SN += int(i)
if int(N) % SN == 0:
    print('Yes')
else:
    print('No')

Nstr = input()
SN = 0
for i in Nstr:
    SN += int(i)
if int(Nstr) % SN == 0:
    print('Yes')
else:
    print('No')


Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(raw_input())
sum = 0
tmp = n

while tmp > 0:
    sum += tmp % 10
    tmp /= 10

if n % sum == 0:
    print("Yes")
else:
    print("No")

n = int(input())
sum = 0
tmp = n

while tmp > 0:
    sum += tmp % 10
    tmp /= 10

if n % sum == 0:
    print("Yes")
else:
    print("No")

n = int(raw_input())
sum = 0
tmp = n

while tmp > 0:
    sum += tmp % 10
    tmp /= 10

if n % sum == 0:
    print "Yes"
else:
    print "No"


N = int(input())

def S(N):
  if N < 10:
    return N
  return N%10 + S(N//10)

answer = 'No' if N%S(N) else 'Yes'
print(answer)

Verdicts: Runtime Error

Wrong Answer

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n=int(input)
sum=0
cnt=n

while cnt>0:
  sum+=cnt%10
  cnt/=10
  
if n%sum==0:
  print("Yes")
else:
  print("No")

n=int(input())
sum=0
cnt=n

while cnt>0:
  sum+=cnt%10
  cnt/=10
  
if n%sum==0:
  print("Yes")
else:
  print("No")


n=int(input())
s=sum(list(str(n)))

if n%s==0:
  print("Yes")
else:
  print("No")

n=input()
print("No" if int(n)%sum(map(int,input())) else "Yes")

n=input()
print("No" if int(n)%sum(map(int,n)) else "Yes")


Verdicts: Runtime Error

Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
A = input()

S = 0
for i in range(0,10):
  S += A[i]
  
if int(A) % S == 0:
  print("Yes")
else:
  print("No")  


A = input()

S = 0
for i in A:
  S += A[i]
  
if int(A) % S == 0:
  print("Yes")
else:
  print("No")  


A = input()

S = 0
for i in A:
  S = S + A[i]
  
if int(A) % S == 0:
  print("Yes")
else:
  print("No")  


A = input()

S = 0
for i in range(0,10):
  S += A[i]
  
if A % S == 0:
  print("Yes")
else:
  print("No")  


A = input()

S = 0
for i in A:
  S = S + A(i)
  
if (int(A) % S) == 0:
  print("Yes")
else:
  print("No")  


A = input()

S = 0
for i in A:
  S = S + int(i)
  
if (int(A) % S) == 0:
  print("Yes")
else:
  print("No")  


Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()
if int(N) % sum([int(N[i] for i in range(len(N)))]) == 0:
    print("Yes")
else:
    print("No")


S = input()
T = input()
if S == T:
    print("Yes")
    exit()
for i in range(N):
    S = S[-1] + S[0 : len(S) - 1]
    if S == T:
        print("Yes")
        exit()
print("No")


N = input()
if int(N) % sum([int(N[i]) for i in range(len(N))]) == 0:
    print("Yes")
else:
    print("No")


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()
sN = 0

for i in N:
  sN += int(i)

print('Yes') if int(N) // sN == 0 else print('No')

N = input()
sN = 0

for i in N:
  sN += int(i)

print('Yes') if int(N) % sN == 0 else print('No')


Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(input())

h = sum(list(str(n)))

print('Yes' if n % h == 0 else 'No')

n = int(input())
h = sum(map(int, list(str(n))))

print('Yes' if n % h == 0 else 'No')

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
def s(n):
  x = 0
  for i in range(len(n)):
    x += int(n[i])
  return x
n = input()
print("Yes") if n % s(n) == 0 else print("No")


def s(n):
  x = 0
  for i in range(len(n)):
    x += int(n[i])
  return x
n = input()
print("Yes" if n % s(n) == 0 else "No")

def s(n):
  x = 0
  for i in range(len(n)):
    x += int(n[i])
  return x
n = input()
print("Yes") if int(n) % s(n) == 0 else print("No")


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()
mod = int(N[0] + N[1] + N[2])

print("Yes" if int(N) % mod == 0 else "No")

N = input()
mod = int(N[0] + N[1] + N[2])

print("Yes" if int(N) % mod == 0 else "No")

N = input()
sum = 0

for i in range(len(N)):
    sum += int(N[i])
print("Yes" if int(N) % sum == 0 else "No")


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
def main14():
    strbuf = input('');
    num = int(strbuf);
    kari = num;
    peku = 0;
    while(True):
        iti = int(kari % 10);
        peku = iti;
        if(iti<10):
            break;
        kari = (kari - iti) / 10;
    if((int(num % peku) == 0)):
        print("Yes");
    else:
        print("No");

def main15():
    strbuf1 = input('');
    strbuf2 = input('');
    buf1 = [];
    buf2 = []
    for i in range(2):


if __name__ == '__main__':
    main14()

def main14():
    strbuf = input('');
    num = int(strbuf);
    kari = num;
    peku = 0;
    while(True):
        iti = int(kari % 10);
        peku = peku + iti;
        if(kari<10):
            break;
        kari = (kari - iti) / 10;
    if((int(num % peku) == 0)):
        print("Yes");
    else:
        print("No");

def main15():
    strbuf1 = input('');
    strbuf2 = input('');
    buf1 = [];
    buf2 = [];
    for i in range(2):
        buf1.append(int(strbuf1[i]));
    for i in range(buf1[0]):
        buf2.append(int(strbuf2[i]));


if __name__ == '__main__':
    main14()

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()

sumN = 0
for i in N:
    sumN += int(i)

if sumN%int(N) == 0:
    print("Yes")
else:
    print("No")


N = input()

sumN = 0
for i in N:
    sumN += int(i)

if int(N)%sumN == 0:
    print("Yes")
else:
    print("No")


Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n=int(input())
print("No" if n%sum(map(int,str(n))) else "No")

n=int(input())
print("No" if n%sum(map(int,str(n))) else "Yes")

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
def divide(n):
    if len(str(n)) <= 1:
        return n

    out = n % 10
    print(n)
    return out + divide(n//10)

n = int(input())
sn = divide(n)

print('Yes' if int(n) % sn == 0 else 'No')


n = input()
sn = sum(map(int, n))

print('Yes' if n % sn == 0 else 'No')

def divide(n):
    if len(str(n)) <= 1:
        return n

    out = n % 10
    
    return out + divide(n//10)

n = int(input())
sn = divide(n)

print('Yes' if int(n) % sn == 0 else 'No')


Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n=int(input())
s=list(str(n))
a=n%(sum(s))

if a==0:
  print('Yes')
else:
  print('No')

n=int(input())
s=list(str(n))
a=n%(sum(s))

if a==0:
  print('Yes')
else:
  print('No')

n=int(input())
s=list(str(n))
for i in range(len(s)):
  s[i]=int(s[i])
b=sum(s)
a=n%b

if a==0:
  print('Yes')
else:
  print('No')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
def S_n(n):
    num = []
    sum = 0
    while n != 0:
        num.append(n % 10)
        n = int(n / 10)
    for i in num:
        sum += i

    return sum

if __name__ == "__main__" :
    num = int(input())
    wa = S_n(num)
    # print(wa)
    if(num % wa == 0):  print("YES")
    else:  print("NO")
    

n=input()
print("Yes" if int(n)%sum(map(int, n))==0 else "No")

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
a = list(input())
su = 0
s = 0
k = 0
for i in a:
  s += int(i)
a.reverse()
for i in a:
  su += i*pow(10,k)
  k += 1
  
if su % s == 0:
  print("Yes")
else:
  print("No")

a = list(input())
su = 0
s = 0
k = 0
for i in a:
  s += int(i)
a.reverse()
for i in a:
  su += int(i)*pow(10,k)
  k += 1
  
if su % s == 0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
s=input()
sum=0
for i in range(len(s)):
   sum+=int(s[i])
if int(s)/sum==0:
  print("Yes")
else:
  print("No")

s=input()
sum=0
for i in range(len(s)):
   sum+=int(s[i])
if int(s)%sum==0:
  print("Yes")
else:
  print("No")

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):

# B - Digit Sums

from sys import stdin
input = stdin.readline

N = input()
S = 0
for i in N:
    S += int(i)

if int(N) % S == 0:
    print('Yes')
else:
    print('No')

import bisect
import heapq
import math
import random
import sys
from collections import Counter, defaultdict, deque
from decimal import Decimal
from functools import lru_cache, reduce
from itertools import combinations, combinations_with_replacement, product, permutations
from operator import add, mul, sub, itemgetter
import numpy as np

sys.setrecursionlimit(10000)

def read_int():
	return int(sys.stdin.readline().strip())

def read_int_n():
	return [int(x) for x in sys.stdin.readline().strip().split()]

def read_float():
	return float(sys.stdin.readline().strip())

def read_float_n():
	return [float(x) for x in sys.stdin.readline().strip().split()]

def read_str():
	return sys.stdin.readline().strip()

def read_str_n():
	return [str(x) for x in sys.stdin.readline().strip().split()]

def error_print(*args):
	print(*args, file=sys.stderr)

def mt(f):
	import time
	def wrap(*args, **kwargs):
		s = time.time()
		ret = f(*args, **kwargs)
		e = time.time()
		error_print(e - s, 'sec')
		return ret
	return wrap

@mt
def slv(N):
	S = 0
	for i in N:
		S += int(i)
		
	if int(N) % S == 0:
		ans = 'Yes'
	else:
		ans = 'No'
		
	return ans

def main():
	N = read_str()
	print(slv(N))

if __name__ == '__main__':
	main()

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n=int(input())
tot=0
while(n>0):
    dig=n%10
    tot=tot+dig
    n=n/10
if (n%tot)==0 :
   print('True')
elif (n%tot)!=0:
   print("False")

num = int(input())
num2 = num
sum = 0
while num2 > 0:
  sum += num2 % 10
  num2 /= 10

if (num % sum) == 0:
  print("Yes")
else:
  print("No")

a=input()
sum=0
for i in a:
    sum=sum+ord(i)-48

a=int(a)
if(a%sum==0):
    print('Yes')
else:
    print('No')

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
nlist = list(map(int,input()))
rev_n = reversed(nlist)
sn = sum(nlist)
n = 0

for i in range(len(nlist)):
    n += rev_n[i]*(10**i) 
if n%sn == 0:
    print("Yes")
else:
    print("No")

nlist = list(map(int,input()))
rev_n = list(reversed(nlist))
sn = sum(nlist)
n = 0

for i in range(len(nlist)):
    n += rev_n[i]*(10**i) 
if n%sn == 0:
    print("Yes")
else:
    print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
def s(n):
	rtn=0
    while n>0:
    	rtn+=n%10
        n//10
    return rtn
n=int(input())
print("Yes" if n%s(n)==0 else "No") 

def s(n):
    rtn=0
    while n>0:
        rtn += n%10
        n//=10
    return rtn
x=int(input())
print('Yes' if x%s(x)==0 else 'No')

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n=int(input())
a=0
for i in range(len(a)):
    a+=str(n)[i]
if n%a==0:
    print("Yes")
else:
    print("No")

n=int(input())
a=0
for i in range(len(str(n))):
    a+=int(str(n)[i])
if n%int(a)==0:
    print("Yes")
else:
    print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
s=input()
print("Yes" if int(s) % sum(list(s)) ==0 else "No")

s=input()
print("Yes" if int(s) % sum(list(map(int,list(s)))) ==0 else "No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
a = int(input())
ar = list(input())
b = 0
for r in ar:
  b += int(r)
if a % b == 0:
  print("Yes")
else:
  print("No")

b = input()
a = int(b)
ar = list(b)
b = 0
for r in ar:
  b += int(r)
if a % b == 0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(input())
s = 0
x = len(n)
for i in range(x):
  a = n[-1 * i]
  s = s+ a
  
if n%a == 0:
  print('Yes')
else:
  print('No')

N = input()
Na = int(N)

def S(N):
  r = list(N)
  p = sum(map(int, r))
  return p

if Na%(S(N)) == 0:
  print('Yes')
else:
  print('No')

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N=int(input())
n=N
i=1
s=0
while n>0:
  s+=n%10
  n=n//10
print(s)
if N%s==0:
  print('Yes')
else:
  print('No')

N=int(input())
n=N
i=1
s=0
while n>0:
  s+=n%10
  n=n//10
if N%s==0:
  print('Yes')
else:
  print('No')

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = input()
s = 0
for x in str(n):
  s += int(x)
if int(n)%s:
  print("Yes")
else:
  print("No")

n = input()
s = 0
for x in str(n):
  s += int(x)
if int(n)%s==0:
  print("Yes")
else:
  print("No")


Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
a=input()
b=int(a)
c=0
for i in range(len(a)):
  c+=int(a[i])
print("YNeos"[b%c!=1::2])

a=input()
b=int(a)
c=0
for i in range(len(a)):
  c+=int(a[i])
print("YNeos"[b%c!=0::2])

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
num = int(input())
num2 = num
sum = 0
while num2 > 0:
  sum += num2 % 10
  num2 /= 10

print("Yes" if sum == num else "No")

n=int(input())
n=str(n)
s=0
for i in n:
    s+=int(i)
if (int(n)%s==0):
    print("Yes")
else:
    print("No")


Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = int(input())
s = list(str(N))
S = 0
for i in range(len(s)):
    S += s[i]

if N % S == 0:
    print("Yes")
else:
    print("No")

s = str(input())
N = int(S)
S = sum(list(s))
if N % S == 0:
    print("Yes")
else:
    print("No")

s = str(input())
N = int(s)
S = sum(list(s))
if N % S == 0:
    print("Yes")
else:
    print("No")


N = int(input())
s = list(str(N))
S = 0
for i in range(len(s)):
    S += int(s[i])

if N % S == 0:
    print("Yes")
else:
    print("No")


Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = int(input())
S = 0

for i in range(len(str(N))):
  S += int(str(S)[i])
  
if N % S == 0:
  print('Yes')
else:
  print('No')

N = int(input())
S = 0

for i in range(len(str(N))):
  S += int(str(N)[i])
  
if N % S == 0:
  print('Yes')
else:
  print('No')



Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()
num = int(N)
Nls = list(N)
sum1 = sum([int(i) for in Nls])
if num%sum1 == 0:
  print('Yes')
else:
  print('No')

N = input()
num = int(N)
Nls = list(N)
sum1 = sum(Nls)
if num%sum1 == 0:
  print('Yes')
else:
  print('No')

N = input()
num = int(N)
Nls = list(N)
sum1 = sum([int(i) for i in Nls])
if num%sum1 == 0:
  print('Yes')
else:
  print('No')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
s=input()
n=int(s)
sn=0
for d in s:
  sn+=int(d)
if n%sn==0:
  Print("Yes")
else:
  print("No")

s=input()
n=int(s)
sn=0
for d in s:
  sn+=int(d)
if n%sn==0:
  print("Yes")
else:
  print("No")


Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()
n = sum(list(map(int,N)))
if(N%n == 0):
  print("Yes")
else:
  print("No")

N = input()

def num(n):
  return list(map(int,n))

if(N%sum(num(N)) == 0):
  print("Yes")
else:
  print("No")

N = int(input())
if(N%sum(list(map(int,str(N)))) == 0):
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
#include <bits/stdc++.h>
using namespace std;

int main() {
    int n, n_origin, s, keta;
    cin >> n;
    n_origin = n;
    s = 0;
    keta = 10;

    while (n >= 1) {
        s += n%10;
        n /= keta;
    }

    if (n_origin%s == 0) {
        cout << "Yes" << endl;
    }
    else {
        cout << "No" << endl;
    }
}

n = int(input())
n_origin = n

s = 0
keta = 10

while n >= 1:
    s += n%10
    n //= keta

if n_origin%s==0:
    print('Yes')
else:
    print('No')

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = int(input())
for i in range(12):
wa = 0
  if N // 10 ** i == 0:
    break
  else:
    wa += N // 10 ** i

if N % wa == 0:
  print("Yes")
else:
  print("No")

N = int(input())
wa = 0
for i in range(12):
  if N // 10 ** i == 0:
    break
  else:
    wa += N // 10 ** i

if N % wa == 0:
  print("Yes")
else:
  print("No")

N = int(input())
wals = list(str(N))
wals = [int(s) for s in wals]
wa = sum(wals)

if N % wa == 0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
S= input().split() 

print(S)
a=0

sum=0
for i in S[0]:
	
	sum=sum+int(i)



anser=int(S[0])%sum






if anser == 0:
	print("Yes")

else : print("No")

S= input().split() 
 

a=0
 
sum=0
for i in S[0]:
	
	sum=sum+int(i)
 
 
 
anser=int(S[0])%sum
 
 
 
 
 
 
if anser == 0:
	print("Yes")
 
else : print("No")

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N=int(input())
n=N
sum=0
while(N>0):
  sum+=N%10
  N=N//10
if sum%n==0:
  print("Yes")
else:
  print("No")


N=int(input())
n=N
sum=0
while(N>0):
  sum+=N%10
  N=N//10
if n%sum==0:
  print("Yes")
else:
  print("No")


Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
#copy code

n=input()
print('Yes' if int(n)%sum(map(int,n)) else 'No')

#copy code

n=input()
print('Yes' if int(n)%sum(map(int,n))==0 else 'No')

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()
S = 0
for n in N:
  S += int(n)

if S % N:
  print('No')
else:
  print('Yes')

N = input()
S = 0
for n in N:
  S += int(n)

if S % int(N):
  print('No')
else:
  print('Yes')

N = input()
S = 0
for n in N:
  S += int(n)

if int(N) % S:
  print('No')
else:
  print('Yes')

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()
s = 0
for i in N:
  s+=int(i)
if(N%s == 0):
  print('Yes')
else:
  print('No')

N = input()
s = 0
for i in N:
  s+=int(i)
if(int(N)%s == 0):
  print('Yes')
else:
  print('No')

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
N = input()
S = sum(map(int, N))

if N % S == 0:
    print("Yes")
else:
    print("No")

N = input()
S = sum(map(int, N))

if int(N) % S == 0:
    print("Yes")
else:
    print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
# coding: utf-8
# Your code here!

s = input()
print(sum(list(map(int,s))))

# coding: utf-8
# Your code here!

s = input()
print('Yes' if int(s)%sum(list(map(int,s)))==0 else 'No')

Verdicts: Wrong Answer

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(input())

def check(p):
  c = 0
  while p > 0:
    c += p % 10
    p //= 10
  return c

if n % check(p) == 0:
  print("Yes")
else:
  print("No")

n = int(input())
 
def check(p):
  c = 0
  while p > 0:
    c += p % 10
    p //= 10
  return c
 
if n % check(n) == 0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
# -*- coding: utf-8 -*-
S = str(input())
L = []
for i in range(len(S)):
  L.append(S[i])
M = sum(L)
if int(S) % M == 0:
  print("Yes")
else:
  print("No")

# -*- coding: utf-8 -*-
S = str(input())
L = []
for i in range(len(S)):
  L.append(int(S[i]))
M = sum(L)
if int(S) % M == 0:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Accepted
Problem: Let S(n) denote the sum of the digits in the decimal notation of n. For example, S(101) = 1 + 0 + 1 = 2.  Given an integer N, determine if S(N) divides N.

Submission attempts (in order):
n = int(input())
num = []
tmp = n
while 1:
    if tmp == 0:
        break
    num.append(int(tmp % 10))
    tmp //= 10
s = sum(num)
if n % s == 0:
    print('YES')
else:
    print('NO')


n = int(input())
num = []
tmp = n
while 1:
    if tmp == 0:
        break
    num.append(int(tmp % 10))
    tmp //= 10
s = sum(num)
if n % s == 0:
    print('Yes')
else:
    print('No')


Verdicts: Wrong Answer

Accepted