Cody

Solution 1914667

Submitted on 28 Aug 2019 by David Hill
  • Size: 97
  • This is the leading solution.
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
N = ''; A='0110000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'; assert(isequal(SHA3(N),reshape(reshape(A-48,[64,25])',[5,5,64])))

2   Pass
N = 'abcdefghijklmnopqrstuvwxyz'; A='1110000000000000000000000100000000000000000000000001000000000000000000000000010000000000000000000000011000000000000000000000000100000000000000000000001110000000000000000000000111000000000000000000000010000000000000000000000000110000000000000000000000000000000000000000000000001000000000000000000000001110000000000000000000000011000000000000000000000011100000000000000000000001000000000000000000000000011000000000000000000000001000000000000000000000000010000000000000000000000101000000000000000000000011100000000000000000000001110000000000000000000000100000000000000000000000001100000000000000000000000110000000000000000000000100000000000000000000000001100000000000000000000000110000000000000000000000111000000000000000000000010000000000000000000000000110000000000000000000000011000000000000000000000011100000000000000000000000010000000000000000000000111000000000000000000000011100000000000000000000001010000000000000000000000010000000000000000000000001000000000000000000000001100000000000000000000000111000000000000000000000001100000000000000000000001110000000000000000000000111000000000000000000000000000000000000000000000000000000000000000000000000101000000000000000000000010100000000000000000000001110000000000000000000000111000000000000000000000011100000000000000000000000000000000000000000000000101000000000000000000000000000000000000000000000000100000000000000000000000011000000000000000000000011100000000000000000000001100000000000000000000000000000000000000000000000010000000000000000000000000100000000000000000000000000000000000000000000000011000000000000000000000001100000000000000010000000'; assert(isequal(SHA3(N),reshape(A-48,[5,5,64])))

3   Pass
N = 'People who succeed have momentum. The more they succeed, the more they want to succeed and the more they find a way to succeed. Similarly, when someone is failing, the tendency is to get on a downward spiral that can even become a self-fulfilling prophecy.'; A='1100100110010011000000000000101010010010011000000011001110100011111100000000101010011011101000000000010111111111000011000000001110110011000101100000000010000111010110100000000110100001010011100000000010110101100011100000000000001001001000100100000000000011001001111001000000010011000011100001100000000011000001100100110000000111110000100001110000000011001001100101110100000001101001100100111100000000000011110101110010000000010001110001110111100000001111110101011011110000000111100100111000111000000011111000110111111000000001110110110001111010000000110111111000111011000000010101110010111011000000000111110110001010100000000000111100011000001000000001111000001000001100000000110010011000111100000000110100011010011101000000010011111001011100000000000010011010001100100000000100111001011101101000000011101001101110101100000000101001011101101010000000011000010100000110000000011011111101101110100000001001010100111110010000000000111110010010101000000000000101001110010000000001100100001110001010000000011100000110010011000000011100001111100101000000000100010010000111000000000101001111100011011000000000100110011111100100000000100110001011000010000000001110101011100010000000001101010111001101100000000111010011011001100000000110010111001001111000000010110111101100110100000001010011101001100000000000011011001011101010000000010111011000101111000000001111001110101101010000000111011111100110110000000011010011100110110000000001010011100001010000000000001001100000011100000000011001110000010110000000000011100010110001010000000001100001110000111000000000100111111000111100000001100100111000001000000000'; assert(isequal(SHA3(N),reshape(A-48,[5,5,64])))

4   Pass
N = 'First, have a definite, clear practical ideal; a goal, an objective. Second, have the necessary means to achieve your ends; wisdom, money, materials, and methods. Third, adjust all your means to that end.'; A='1100010111000111000000000011011110001111011000000000101010111111011000000000111110110101011010000000110110001011111001000000010110000011001101100000000111000111001110110000000110000111000101110000000010100011010001100100000000001111100001100000000000110011001011101010000000000101011001100101100000000111001101110100010000000101010100110101110000000011101001100100010100000001000010100001110100000000101000101110010110000000000000100100111110000000000001100101110010010000000101100000010000101000000001110001011101011000000001100000010110101010000000100000110001001001000000010100110000111000100000000000110100101100010000000001110110001110001000000011010011011010011100000001011111011000101100000000110001101000011100000000010100111010010110100000001011111011001100000000000000011000101101100000000010011000001100101100000000001010001101000110000000011001101100101111000000001001101101010110000000001000011000101110100000000000001110101110011000000011011100001111111100000001001101001111010000000000001100011110011111000000001100011110011111000000000100100110000111010000000100001111011111101000000000011110000111001100000000111110011111010000000000001110011111111100000000001110110011000100100000000111010111010001100000000110000111000111100000000010110011000001100000000000010101001000101000000000110011001011110000000000001011000011100100100000000011010111100001100000000011011110101011111000000011011011111001110000000001000001100100110110000000011000100011111010000000000010111010110100000000000011100101110000110000000011110110110010111000000011101001111010111000000001100000111010001010000000'; assert(isequal(SHA3(N),reshape(A-48,[5,5,64])))