Submission #2719378


Source Code Expand

Copy
$n = <>; chomp $n;
@sn = split //, $n;
$hoge = 0;
$hoge += $_ for @sn;

print $n % $hoge ? 'No' : 'Yes';

Submission Info

Submission Time
Task B - Digit Sums
User tsukumaru
Language Perl (v5.18.2)
Score 200
Code Size 111 Byte
Status
Exec Time 2 ms
Memory 512 KB

Compile Error

./Main.pl syntax OK

Test Cases

Set Name Score / Max Score Test Cases
Sample 0 / 0 sample1.txt, sample2.txt, sample3.txt
All 200 / 200 sample1.txt, sample2.txt, sample3.txt, 1.txt, 2.txt, 3.txt, 4.txt, 5.txt, 6.txt, 7.txt, 8.txt, sample1.txt, sample2.txt, sample3.txt
Case Name Status Exec Time Memory
1.txt 2 ms 512 KB
2.txt 1 ms 384 KB
3.txt 2 ms 384 KB
4.txt 2 ms 384 KB
5.txt 2 ms 384 KB
6.txt 2 ms 384 KB
7.txt 2 ms 384 KB
8.txt 2 ms 384 KB
sample1.txt 2 ms 384 KB
sample2.txt 2 ms 384 KB
sample3.txt 2 ms 384 KB