Cody

Solution 607385

Submitted on 27 Mar 2015 by Alexander Razmyslov
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   Pass
%% a = 124; b = 545; assert(isequal(find_palindrome(a),b))

trueFalse = 0 vektor_a = 1 2 4 flip_a = 421 sum_a = 545 vektor_sum_a = 5 4 5 trueFalse = 1 a = 545 b = 545

2   Pass
%% a = 150; b = 303; assert(isequal(find_palindrome(a),b))

trueFalse = 0 vektor_a = 1 5 0 flip_a = 51 sum_a = 201 vektor_sum_a = 2 0 1 trueFalse = 0 a = 201 vektor_a = 2 0 1 flip_a = 102 sum_a = 303 vektor_sum_a = 3 0 3 trueFalse = 1 a = 303 b = 303

3   Pass
%% a = 291; b = 6996; assert(isequal(find_palindrome(a),b))

trueFalse = 0 vektor_a = 2 9 1 flip_a = 192 sum_a = 483 vektor_sum_a = 4 8 3 trueFalse = 0 a = 483 vektor_a = 4 8 3 flip_a = 384 sum_a = 867 vektor_sum_a = 8 6 7 trueFalse = 0 a = 867 vektor_a = 8 6 7 flip_a = 768 sum_a = 1635 vektor_sum_a = 1 6 3 5 trueFalse = 0 a = 1635 vektor_a = 1 6 3 5 flip_a = 5361 sum_a = 6996 vektor_sum_a = 6 9 9 6 trueFalse = 1 a = 6996 b = 6996

4   Pass
%% a = 178; b = 15851; assert(isequal(find_palindrome(a),b))

trueFalse = 0 vektor_a = 1 7 8 flip_a = 871 sum_a = 1049 vektor_sum_a = 1 0 4 9 trueFalse = 0 a = 1049 vektor_a = 1 0 4 9 flip_a = 9401 sum_a = 10450 vektor_sum_a = 1 0 4 5 0 trueFalse = 0 a = 10450 vektor_a = 1 0 4 5 0 flip_a = 5401 sum_a = 15851 vektor_sum_a = 1 5 8 5 1 trueFalse = 1 a = 15851 b = 15851

Suggested Problems

More from this Author95