Cody

Solution 673448

Submitted on 21 May 2015 by Tim
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

This solution is outdated. To rescore this solution, sign in.

Test Suite

Test Status Code Input and Output
1   Pass
%% assert(isequal(symmetry(27),3))

2   Pass
%% assert(isequal(symmetry(801),0))

3   Pass
%% assert(isequal(symmetry(900),100))

4   Pass
%% assert(isequal(symmetry(1234567),65433))

5   Pass
%% assert(isequal(symmetry(34567890),3432110))

6   Pass
%% format long g x=ceil(1e9*rand); j=389e9+x assert(isequal(8e11-symmetry(j),j))

j = 389364710637

7   Pass
%% format long g x=ceil(1e10*rand); j=889e10+x v=symmetry(j); assert(isequal(1e13-v,j))

j = 8898643449421

8   Pass
%% x=2^40-1; assert(isequal(symmetry(symmetry(symmetry(symmetry(x)))),7775))