Cody

Problem 1084. Square Digits Number Chain Terminal Value (Inspired by Project Euler Problem 92)

Solution 2005622

Submitted on 6 Nov 2019
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Fail
assert(digits_squared_chain(649) == 1)

133

Assertion failed.

2   Fail
assert(digits_squared_chain(79) == 1)

130

Assertion failed.

3   Fail
assert(digits_squared_chain(608) == 1)

100

Assertion failed.

4   Fail
assert(digits_squared_chain(487) == 1)

129

Assertion failed.

5   Fail
assert(digits_squared_chain(739) == 1)

139

Assertion failed.

6   Fail
assert(digits_squared_chain(565) == 1)

86

Assertion failed.

7   Fail
assert(digits_squared_chain(68) == 1)

100

Assertion failed.

8   Fail
assert(digits_squared_chain(383) == 1)

82

Assertion failed.

9   Fail
assert(digits_squared_chain(379) == 1)

139

Assertion failed.

10   Fail
assert(digits_squared_chain(203) == 1)

13

Assertion failed.

11   Fail
assert(digits_squared_chain(632) == 1)

49

Assertion failed.

12   Fail
assert(digits_squared_chain(391) == 1)

91

Assertion failed.

13   Fail
assert(digits_squared_chain(863) == 1)

109

Assertion failed.

14   Fail
assert(digits_squared_chain(13) == 1)

10

Assertion failed.

15   Pass
assert(digits_squared_chain(100) == 1)

1

16   Fail
assert(digits_squared_chain(236) == 1)

49

Assertion failed.

17   Fail
assert(digits_squared_chain(293) == 1)

94

Assertion failed.

18   Fail
assert(digits_squared_chain(230) == 1)

13

Assertion failed.

19   Fail
assert(digits_squared_chain(31) == 1)

10

Assertion failed.

20   Fail
assert(digits_squared_chain(806) == 1)

100

Assertion failed.

21   Fail
assert(digits_squared_chain(623) == 1)

49

Assertion failed.

22   Fail
assert(digits_squared_chain(7) == 1)

49

Assertion failed.

23   Fail
assert(digits_squared_chain(13) == 1)

10

Assertion failed.

24   Fail
assert(digits_squared_chain(836) == 1)

109

Assertion failed.

25   Fail
assert(digits_squared_chain(954) == 89)

122

Assertion failed.

26   Fail
assert(digits_squared_chain(567) == 89)

110

Assertion failed.

27   Fail
assert(digits_squared_chain(388) == 89)

137

Assertion failed.

28   Fail
assert(digits_squared_chain(789) == 89)

194

Assertion failed.

29   Fail
assert(digits_squared_chain(246) == 89)

56

Assertion failed.

30   Fail
assert(digits_squared_chain(787) == 89)

162

Assertion failed.

31   Fail
assert(digits_squared_chain(311) == 89)

11

Assertion failed.

32   Fail
assert(digits_squared_chain(856) == 89)

125

Assertion failed.

33   Fail
assert(digits_squared_chain(143) == 89)

26

Assertion failed.

34   Fail
assert(digits_squared_chain(873) == 89)

122

Assertion failed.

35   Fail
assert(digits_squared_chain(215) == 89)

30

Assertion failed.

36   Fail
assert(digits_squared_chain(995) == 89)

187

Assertion failed.

37   Fail
assert(digits_squared_chain(455) == 89)

66

Assertion failed.

38   Fail
assert(digits_squared_chain(948) == 89)

161

Assertion failed.

39   Fail
assert(digits_squared_chain(875) == 89)

138

Assertion failed.

40   Fail
assert(digits_squared_chain(788) == 89)

177

Assertion failed.

41   Fail
assert(digits_squared_chain(722) == 89)

57

Assertion failed.

42   Fail
assert(digits_squared_chain(250) == 89)

29

Assertion failed.

43   Fail
assert(digits_squared_chain(227) == 89)

57

Assertion failed.

44   Fail
assert(digits_squared_chain(640) == 89)

52

Assertion failed.

45   Fail
assert(digits_squared_chain(835) == 89)

98

Assertion failed.

46   Fail
assert(digits_squared_chain(965) == 89)

142

Assertion failed.

47   Pass
assert(digits_squared_chain(726) == 89)

89

48   Fail
assert(digits_squared_chain(689) == 89)

181

Assertion failed.

Suggested Problems

More from this Author56