コード例 #1
0
 public void TestDigitSum()
 {
     Assert.Equal(21, Manipulator.DigitSum(353235));
     Assert.Equal(19, Manipulator.DigitSum(34534));
     Assert.Equal(8, Manipulator.DigitSum(8));
     Assert.Equal(7, Manipulator.DigitSum(133));
     Assert.Equal(0, Manipulator.DigitSum(0));
     Assert.Equal(1, Manipulator.DigitSum(1));
     Assert.Equal(12, Manipulator.DigitSum(453));
     Assert.Equal(42, Manipulator.DigitSum(89988));
 }