Cody

Solution 1786183

Submitted on 13 Apr 2019 by Eric Mueller
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
for i=1:randi(1000) vec = randperm(100); end vec = randperm(100); a = vec(1:50); % given to bot b = vec(51:100); % given to player you = 0; bot = 0; for i = 1:50 c = call(a(1),b); if ~ismember(c,b) while(1) end end if c>a(1) you = you + 1; else bot = bot + 1; end b(b==c)=[]; a(1)=[]; end if you<floor(50*0.75) while(1) disp('not enough wins'); end end

c = Columns 1 through 30 28 29 31 33 35 36 37 42 45 46 48 50 54 58 59 60 61 62 64 65 66 67 68 69 72 75 77 78 79 81 Columns 31 through 39 82 83 84 87 91 92 93 96 98 y = 28 c = 91 92 93 96 98 y = 91 c = 77 78 79 81 82 83 84 87 92 93 96 98 y = 77 c = Columns 1 through 30 29 31 33 35 36 37 42 45 46 48 50 54 58 59 60 61 62 64 65 66 67 68 69 72 75 78 79 81 82 83 Columns 31 through 36 84 87 92 93 96 98 y = 29 c = Columns 1 through 30 33 35 36 37 42 45 46 48 50 54 58 59 60 61 62 64 65 66 67 68 69 72 75 78 79 81 82 83 84 87 Columns 31 through 34 92 93 96 98 y = 33 c = 72 75 78 79 81 82 83 84 87 92 93 96 98 y = 72 c = 54 58 59 60 61 62 64 65 66 67 68 69 75 78 79 81 82 83 84 87 92 93 96 98 y = 54 c = 1×0 empty double row vector y = 2 c = Columns 1 through 30 17 21 31 35 36 37 42 45 46 48 50 58 59 60 61 62 64 65 66 67 68 69 75 78 79 81 82 83 84 87 Columns 31 through 34 92 93 96 98 y = 17 c = Columns 1 through 30 21 31 35 36 37 42 45 46 48 50 58 59 60 61 62 64 65 66 67 68 69 75 78 79 81 82 83 84 87 92 Columns 31 through 33 93 96 98 y = 21 c = 48 50 58 59 60 61 62 64 65 66 67 68 69 75 78 79 81 82 83 84 87 92 93 96 98 y = 48 c = 50 58 59 60 61 62 64 65 66 67 68 69 75 78 79 81 82 83 84 87 92 93 96 98 y = 50 c = 42 45 46 58 59 60 61 62 64 65 66 67 68 69 75 78 79 81 82 83 84 87 92 93 96 98 y = 42 c = 75 78 79 81 82 83 84 87 92 93 96 98 y = 75 c = 31 35 36 37 45 46 58 59 60 61 62 64 65 66 67 68 69 78 79 81 82 83 84 87 92 93 96 98 y = 31 c = 35 36 37 45 46 58 59 60 61 62 64 65 66 67 68 69 78 79 81 82 83 84 87 92 93 96 98 y = 35 c = 96 98 y = 96 c = 45 46 58 59 60 61 62 64 65 66 67 68 69 78 79 81 82 83 84 87 92 93 98 y = 45 c = 78 79 81 82 83 84 87 92 93 98 y = 78 c = 92 93 98 y = 92 c = 1×0 empty double row vector y = 3 c = 81 82 83 84 87 93 98 y = 81 c = 58 59 60 61 62 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 58 c = 36 37 46 59 60 61 62 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 36 c = 46 59 60 61 62 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 46 c = 59 60 61 62 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 59 c = 13 14 15 37 60 61 62 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 13 c = 60 61 62 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 60 c = 14 15 37 61 62 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 14 c = 15 37 61 62 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 15 c = 37 61 62 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 37 c = 64 65 66 67 68 69 79 82 83 84 87 93 98 y = 64 c = 61 62 65 66 67 68 69 79 82 83 84 87 93 98 y = 61 c = 87 93 98 y = 87 c = 62 65 66 67 68 69 79 82 83 84 93 98 y = 62 c = 65 66 67 68 69 79 82 83 84 93 98 y = 65 c = 66 67 68 69 79 82 83 84 93 98 y = 66 c = 67 68 69 79 82 83 84 93 98 y = 67 c = 79 82 83 84 93 98 y = 79 c = 98 y = 98 c = 68 69 82 83 84 93 y = 68 c = 5 6 7 8 69 82 83 84 93 y = 5 c = 93 y = 93 c = 1×0 empty double row vector y = 6 c = 69 82 83 84 y = 69 c = 82 83 84 y = 82 c = 1×0 empty double row vector y = 7 c = 83 84 y = 83 c = 8 84 y = 8 c = 84 y = 84