{"group":{"id":1,"name":"Community","lockable":false,"created_at":"2012-01-18T18:02:15.000Z","updated_at":"2026-04-06T14:01:22.000Z","description":"Problems submitted by members of the MATLAB Central community.","is_default":true,"created_by":161519,"badge_id":null,"featured":false,"trending":false,"solution_count_in_trending_period":0,"trending_last_calculated":"2026-04-06T00:00:00.000Z","image_id":null,"published":true,"community_created":false,"status_id":2,"is_default_group_for_player":false,"deleted_by":null,"deleted_at":null,"restored_by":null,"restored_at":null,"description_opc":null,"description_html":null,"published_at":null},"problems":[{"id":2313,"title":"Narcissistic problem","description":"How many likes has this problem?","description_html":"\u003cp\u003eHow many likes has this problem?\u003c/p\u003e","function_template":"function y = like_me(x)\r\n  y = x;\r\nend","test_suite":"%%\r\n% this problem will be updated,\r\n% your score/size can change over time\r\n% if you submit a fixed value :-)\r\n%%\r\ny=like_me();\r\nassert(isequal(mod(y,1),0));\r\n%%\r\ny=like_me();\r\nassert(y\u003e0);\r\n%%\r\ny=like_me();\r\nurl='http://www.mathworks.co.uk/matlabcentral/cody/problems/2313'\r\n% the main problem with this problem is that ...\r\n% this problem thinks.\r\n% it thinks about itself most of the time.\r\n% it is convinced, that at least X likes has it.\r\ny_sub_correct=max([10 cellfun(@(S)str2num(cell2mat(S)),regexp(urlread(url),'(\\d*) players\u003c/a\u003e like this problem','tokens'))]); % probably hackable by comments?\r\nt = mtree('like_me.m','-file');\r\nsize = length(t.nodesize);\r\n% this problem likes compliments,\r\n% even false.\r\n% For good compliment it is going to pass your solution with a smaller size! \r\n% But if you don't appreciate it, it can punish you...\r\nfeval(@assignin,'caller','score',round(max(0,size*(.5+.5*y_sub_correct/y))));\r\n","published":true,"deleted":false,"likes_count":30,"comments_count":4,"created_by":14358,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":166,"test_suite_updated_at":"2014-12-05T16:31:19.000Z","rescore_all_solutions":true,"group_id":1,"created_at":"2014-05-08T09:18:27.000Z","updated_at":"2026-02-14T16:20:13.000Z","published_at":"2014-05-08T09:25:53.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eHow many likes has this problem?\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":2312,"title":"How many solutions has this problem?","description":"Guess, predict or calculate :-)\r\n\r\n(You will be scored by the accuracy).\r\n\r\n\r\n\r\n\r\nUpdate: \u003chttp://www.mathworks.co.uk/matlabcentral/about/trendy/ TRENDY\u003e \u003chttp://www.mathworks.co.uk/matlabcentral/trendy/Tutorial/urlfilter.html is\u003e here!","description_html":"\u003cp\u003eGuess, predict or calculate :-)\u003c/p\u003e\u003cp\u003e(You will be scored by the accuracy).\u003c/p\u003e\u003cp\u003eUpdate: \u003ca href = \"http://www.mathworks.co.uk/matlabcentral/about/trendy/\"\u003eTRENDY\u003c/a\u003e \u003ca href = \"http://www.mathworks.co.uk/matlabcentral/trendy/Tutorial/urlfilter.html\"\u003eis\u003c/a\u003e here!\u003c/p\u003e","function_template":"function y = solutions(x)\r\n  y = 42;\r\nend","test_suite":"%%\r\n% please ''ignore'' this first test, this code is here to put function \r\n% urlfilter known from matlabcentral/trendy to the path for this problem\r\n% (method taken from Doug's Hull problem Steal, Share, or Catch)\r\nfh=fopen('urlfilter.m','wt');\r\nfprintf(fh, '%s \\n', 'function out = urlfilter(url, target, numNumbers, direction)') ;\r\nfprintf(fh, '%s \\n', '  if nargin \u003c 3, numNumbers = 1; end');\r\nfprintf(fh, '%s \\n', '  if nargin \u003c 4 direction = ''forward''; end');\r\nfprintf(fh, '%s \\n', '  % If url is not an actual URL, then treat it as a string');\r\nfprintf(fh, '%s \\n', '  if strcmp(url(1:4),''http''), textStr = urlread(url); else textStr = url; end');\r\nfprintf(fh, '%s \\n', '  % Handle special case where two numbers are given as part of a range');\r\nfprintf(fh, '%s \\n', '  %   Example: \"annual rainfall = 20-40 inches\"');\r\nfprintf(fh, '%s \\n', '  % Solution is a pre-processing step that replaces the dash with a space');\r\nfprintf(fh, '%s \\n', '  %   Example: \"annual rainfall = 20 40 inches\"');\r\nfprintf(fh, '%s \\n', '  textStr = regexprep(textStr,''(\\d+)-(\\d+)'',''$1 $2'');');\r\nfprintf(fh, '%s \\n', '  strIndex = strfind(textStr,target);');\r\nfprintf(fh, '%s \\n', '  if isempty(strIndex),');\r\nfprintf(fh, '%s \\n', '    error( ''trendy:urlfilter:TargetStringNotFound'', ...');\r\nfprintf(fh, '%s \\n', '          [''Target string '' target '' does not appear''])');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', '  % Start looking after the first appearance of the target');\r\nfprintf(fh, '%s \\n', '  if strcmp(direction,''forward'')');\r\nfprintf(fh, '%s \\n', '    strIndex = strIndex(1) + length(target);');\r\nfprintf(fh, '%s \\n', '  elseif strcmp(direction,''backward'')');\r\nfprintf(fh, '%s \\n', '    strIndex = strIndex(1) - 1;');\r\nfprintf(fh, '%s \\n', '  else');\r\nfprintf(fh, '%s \\n', '    error( ''trendy:urlfilter:InvalidDirectionFlag'', ...');\r\nfprintf(fh, '%s \\n', '           ''DIRECTION must be either ''''forward'''' or ''''backward''''.'' );');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', '  out = zeros(1,numNumbers);');\r\nfprintf(fh, '%s \\n', '  for i = 1:numNumbers');\r\nfprintf(fh, '%s \\n', '    [out(i),strIndex] = getNextNumber(textStr,strIndex,direction);');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', 'end');\r\nfprintf(fh, '%s \\n', '% =========================');\r\nfprintf(fh, '%s \\n', 'function [nextNumber,strIndex] = getNextNumber(textStr,strIndex,direction)');\r\nfprintf(fh, '%s \\n', '  % Use a state machine to sift through the HTML for numbers.');\r\nfprintf(fh, '%s \\n', '  if strcmp(direction,''forward'')');\r\nfprintf(fh, '%s \\n', '    openTagSymbol  = ''\u003c'';');\r\nfprintf(fh, '%s \\n', '    closeTagSymbol = ''\u003e'';');\r\nfprintf(fh, '%s \\n', '    moveIndexFcn   = @(x) x+1;');\r\nfprintf(fh, '%s \\n', '    concatenateFcn = @(a,b) [a b];');\r\nfprintf(fh, '%s \\n', '  else');\r\nfprintf(fh, '%s \\n', '    openTagSymbol  = ''\u003e'';');\r\nfprintf(fh, '%s \\n', '    closeTagSymbol = ''\u003c'';');\r\nfprintf(fh, '%s \\n', '    moveIndexFcn   = @(x) x-1;');\r\nfprintf(fh, '%s \\n', '    concatenateFcn = @(a,b) [b a];');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', '  urlStrLen = length(textStr);');\r\nfprintf(fh, '%s \\n', '  state = ''notnumber'';');\r\nfprintf(fh, '%s \\n', '  while true');\r\nfprintf(fh, '%s \\n', '    ch = textStr(strIndex);');\r\nfprintf(fh, '%s \\n', '    switch state');\r\nfprintf(fh, '%s \\n', '      case ''notnumber''');\r\nfprintf(fh, '%s \\n', '        if isDigitDotDashOrComma(ch)');\r\nfprintf(fh, '%s \\n', '          state = ''number'';');\r\nfprintf(fh, '%s \\n', '          numStr = ch;');\r\nfprintf(fh, '%s \\n', '        elseif (ch == openTagSymbol)');\r\nfprintf(fh, '%s \\n', '          state = ''tagbody'';');\r\nfprintf(fh, '%s \\n', '        end');\r\nfprintf(fh, '%s \\n', '      case ''tagbody''');\r\nfprintf(fh, '%s \\n', '        % Throw away anything inside the tag markup area');\r\nfprintf(fh, '%s \\n', '        if (ch == closeTagSymbol)');\r\nfprintf(fh, '%s \\n', '          state = ''notnumber'';');\r\nfprintf(fh, '%s \\n', '        end ');\r\nfprintf(fh, '%s \\n', '      case ''number''');\r\nfprintf(fh, '%s \\n', '        if isDigitDotDashOrComma(ch)');\r\nfprintf(fh, '%s \\n', '          numStr = concatenateFcn(numStr,ch);');\r\nfprintf(fh, '%s \\n', '        else');\r\nfprintf(fh, '%s \\n', '          % We are transitioning out of a number.');\r\nfprintf(fh, '%s \\n', '          % Note that STR2DOUBLE handles commas in the string.');\r\nfprintf(fh, '%s \\n', '          nextNumber = str2double(numStr);');\r\nfprintf(fh, '%s \\n', '          if ~isnan(nextNumber)');\r\nfprintf(fh, '%s \\n', '            % The number is valid. We''re all done.');\r\nfprintf(fh, '%s \\n', '            break');\r\nfprintf(fh, '%s \\n', '          else');\r\nfprintf(fh, '%s \\n', '            % The number is bogus. Throw it away and continue.');\r\nfprintf(fh, '%s \\n', '            if (ch == openTagSymbol), state = ''tagbody''; else state = ''notnumber''; end');\r\nfprintf(fh, '%s \\n', '          end');\r\nfprintf(fh, '%s \\n', '        end');\r\nfprintf(fh, '%s \\n', '      otherwise');\r\nfprintf(fh, '%s \\n', '        error( ''trendy:urlfilter:InvalidState'', ...');\r\nfprintf(fh, '%s \\n', '             [''Encountered unknown state '' state])');\r\nfprintf(fh, '%s \\n', '    end');\r\nfprintf(fh, '%s \\n', '    strIndex = moveIndexFcn(strIndex);');\r\nfprintf(fh, '%s \\n', '    if (strIndex == 0) || (strIndex \u003e urlStrLen)');\r\nfprintf(fh, '%s \\n', '      % We ran off the end of the string.');\r\nfprintf(fh, '%s \\n', '      disp(''End of file reached.'')');\r\nfprintf(fh, '%s \\n', '      break');\r\nfprintf(fh, '%s \\n', '    end');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', 'end');\r\nfprintf(fh, '%s \\n', '% ==================');\r\nfprintf(fh, '%s \\n', 'function tf = isDigitDotDashOrComma(ch)');\r\nfprintf(fh, '%s \\n', '  tf = ((ch \u003e= ''0'') \u0026\u0026 (ch \u003c= ''9'')) || ...');\r\nfprintf(fh, '%s \\n', '          (ch == ''.'') || (ch == ''-'') || (ch == '','');');\r\nfprintf(fh, '%s \\n', 'end');\r\nfclose(fh);\r\n%%\r\nrehash path\r\n%%\r\ny=solutions();\r\nassert(isequal(mod(y,1),0))\r\n%%\r\ny=solutions();\r\nassert(y\u003e0);\r\n%%\r\ny=solutions();\r\n% yes, yes solution hidden in the test suite... try to code adifferent one! :-)\r\nurl='http://www.mathworks.co.uk/matlabcentral/cody/problems/2312'\r\ny_correct=max([0 cellfun(@(S)str2num(cell2mat(S)),regexp(urlread(url),'\u003cspan class=\"solution_statistic\"\u003e(\\d*)\u003c/span\u003e\u003cspan class=\"text\"\u003e Solutions\u003c/span\u003e','tokens'))]) + 1; % don't forget your solution\r\nt = mtree('solutions.m','-file');\r\nsize = ceil(length(t.nodesize)/13);\r\nfeval(@assignin,'caller','score',abs(y-y_correct)+size);\r\n% (... and solutions will be rescored from time to time :-D)\r\n","published":true,"deleted":false,"likes_count":2,"comments_count":1,"created_by":14358,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":68,"test_suite_updated_at":"2014-05-12T12:02:31.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2014-05-08T08:33:51.000Z","updated_at":"2026-02-18T14:23:20.000Z","published_at":"2014-05-08T09:06:48.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eGuess, predict or calculate :-)\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e(You will be scored by the accuracy).\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eUpdate:\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"http://www.mathworks.co.uk/matlabcentral/about/trendy/\\\"\u003e\u003cw:r\u003e\u003cw:t\u003eTRENDY\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"http://www.mathworks.co.uk/matlabcentral/trendy/Tutorial/urlfilter.html\\\"\u003e\u003cw:r\u003e\u003cw:t\u003eis\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003cw:r\u003e\u003cw:t\u003e here!\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":1969,"title":"Self-Description","description":"This is a simplified version of the \u003chttp://xkcd.com/688/ *xkcd comic* by the same name\u003e.\r\n\r\nSimply return the angle (in degrees) of the 'black' sector of the pie chart that would make the graph description accurate. \r\n\r\n\u003c\u003chttp://www.alfnie.com/software/self_description02.png\u003e\u003e\r\n\r\n*Details:*\r\n\r\nAssume that the pie chart circle covers 36% of the total image area, and that the text, textbox lines, image frame, and outer circumference of the pie (anything painted in black except the pie chart 'black' sector) add up to 6.4% of the total image area. \r\n\r\nReturn the angle in degrees rounded to 4 decimals. \r\n\r\n_(\"detail oriented\" players may also assume that the portion of the textbox line which is white (overlapping the pie chart 'black' sector) has already been discounted twice from the 6.4% value above)_","description_html":"\u003cp\u003eThis is a simplified version of the \u003ca href = \"http://xkcd.com/688/\"\u003e\u003cb\u003exkcd comic\u003c/b\u003e by the same name\u003c/a\u003e.\u003c/p\u003e\u003cp\u003eSimply return the angle (in degrees) of the 'black' sector of the pie chart that would make the graph description accurate.\u003c/p\u003e\u003cimg src = \"http://www.alfnie.com/software/self_description02.png\"\u003e\u003cp\u003e\u003cb\u003eDetails:\u003c/b\u003e\u003c/p\u003e\u003cp\u003eAssume that the pie chart circle covers 36% of the total image area, and that the text, textbox lines, image frame, and outer circumference of the pie (anything painted in black except the pie chart 'black' sector) add up to 6.4% of the total image area.\u003c/p\u003e\u003cp\u003eReturn the angle in degrees rounded to 4 decimals.\u003c/p\u003e\u003cp\u003e\u003ci\u003e(\"detail oriented\" players may also assume that the portion of the textbox line which is white (overlapping the pie chart 'black' sector) has already been discounted twice from the 6.4% value above)\u003c/i\u003e\u003c/p\u003e","function_template":"function y = piechartangle()\r\n  y = 0;\r\nend","test_suite":"%%\r\nx=piechartangle();\r\nfh=fopen('piechartsolve.p','wb');\r\nfwrite(fh,[118 48 48 46 48 48 118 48 48 46 48 48 0 11 128 28 125 74 255 181 0 0 0 25 0 0 0 78 0 0 0 92 156 161 5 75 80 198 68 25 192 231 52 174 146 57 247 190 205 171 201 55 20 32 41 236 44 207 69 16 38 248 227 160 126 226 43 179 24 228 144 238 252 176 180 231 39 58 57 58 199 133 221 150 59 133 10 11 178 192 106 190 200 24 28 65 163 222 66 234 89 229 14 65 91 62 9 219 22 159],'uchar');\r\nfclose(fh);\r\nrehash;\r\nassert(piechartsolve(x));\r\n","published":true,"deleted":false,"likes_count":4,"comments_count":6,"created_by":43,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":29,"test_suite_updated_at":"2013-11-02T07:06:04.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2013-11-02T06:34:57.000Z","updated_at":"2025-12-30T14:06:23.000Z","published_at":"2013-11-02T07:06:04.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/image\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/media/image1.png\"}],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eThis is a simplified version of the\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"http://xkcd.com/688/\\\"\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003exkcd comic\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e by the same name\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003cw:r\u003e\u003cw:t\u003e.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSimply return the angle (in degrees) of the 'black' sector of the pie chart that would make the graph description accurate.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:customXml w:element=\\\"image\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"height\\\" w:val=\\\"-1\\\"/\u003e\u003cw:attr w:name=\\\"width\\\" w:val=\\\"-1\\\"/\u003e\u003cw:attr w:name=\\\"relationshipId\\\" w:val=\\\"rId1\\\"/\u003e\u003c/w:customXmlPr\u003e\u003c/w:customXml\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eDetails:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eAssume that the pie chart circle covers 36% of the total image area, and that the text, textbox lines, image frame, and outer circumference of the pie (anything painted in black except the pie chart 'black' sector) add up to 6.4% of the total image area.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eReturn the angle in degrees rounded to 4 decimals.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:i/\u003e\u003c/w:rPr\u003e\u003cw:t\u003e(\\\"detail oriented\\\" players may also assume that the portion of the textbox line which is white (overlapping the pie chart 'black' sector) has already been discounted twice from the 6.4% value above)\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"},{\"partUri\":\"/media/image1.png\",\"contentType\":\"image/png\",\"content\":\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAO4AAAC0CAIAAAAcmYfkAAArA0lEQVR42u2deVzP2f7HC1GTpSyFUhSyJAyKrFmzU7Jl3xJjG8tYZ362sQ7ZxnLt1GCmsSeUfWkMUo2tMK4RDcPMpBgG/Z63c+/nfm+S+vatvst5/dHj8/302c45r/N+v95nNTKSkNBxmJub//Of//zXUbNmzebPn/9/EhK6hnnz5nXo0MHExOTfVOZUioSEbuIf//gHHJZUlpBUlpCQVJaQkFSWkJBUlpBUlpCQVJaQkFSWkMgJKv/222/Tp0/fuXPngwcP/v77b87cvXt3//79gYGBJ0+efP36dQb3xsfHh4eH//7778qZv/766+XLl5n5yj///HPq1Klcn8E1vJ2nvXr1iuM3qZClK6n8Xvzwww9cVrRoUUtLywoVKtSsWbN48eLOzs5NmjQpXbr00KFDxWUhISHjxo27d++ecuPnn3/OBdzSvn371atXd+vWrWHDhtxYo0aNH3/8UVyzdu3aDRs2KBQ8c+bM9evXxfHPP/9cqVKlhIQE1Y/ZvHlz3759qUIccyVPK1++PJdVq1bN3t7++++/l6UrqfxeREVFwchbt25xcODAgSFDhnDX6dOn+Rfm1t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2FHL20clco/KGDbsLmoBTfzy5cvq1avb29sTshQtWlQ0SSLgli5d2rVrVzQcTk25EU5zwbRp08aMGdOkSROorLqoo6CyoGyPHj3e3Y8R0y4WjlEGoPETjcgBtQhyX7lyhePhw4dze6VKlVQHfnh4eGDme/XqJYtcUvm/wJFBRBiMlrh8+bKTkxN2dPr06WJtAOJxYo7FixdjFyGlIgkA1/BfeIZxHTRoEJpbddh+WFgYYiAlddgKVtnR0XHixImqbSPcyBOIO2fMmEE1wLfWq1cP4y2qgVjMivPISjc3N4y0avQp1mTgq2SRSyr/F2JVNRiMs4Y3+O7mzZuLBVlw5RCUOBoB16xZM0K0M2fOKDf269cPyyqOz58/j+FUnTWEaHF2dk75z+wS/uXi4qK6ExYaRvmJ/itWrBiuAEGZktrLCI83btyIIB46dCivhs1KPUHZlyxZkq9F7QjLLSGp/C88efLE0tISk8nxgAEDoBcGVaxlAbDWISEhMPizzz6DyhhgrOzRo0eRJZBMCfsuXbpkZ2enOsBq165dQo1w5dRUYGKVJbZSUlcJwRvcu3ePYJEwH0VRqlQpwqCEhATqEkRXGjqGDRuGZB81alRK6tA8BwcHUhceHu7n56e6bJeEoVMZICEgkLCgaYIzuIVVVjQDpMcWYjJRz0SBStsZKhnbGR8fr9z422+/ifpw6NAhRDAKIc3ejLGxsSgZ7CsMtrGxOXny5MqVK/lsjk1MTJQVko4cORIaGsoXwnVEfIkSJaZMmRIcHBwVFZWSupyhWPBOLxukJJVzsOMayt66dUtVEytITEzMauM81Qar/Msvv4hxC69evTp48CBndu7cefjw4Xe9R1BQkFjlSBVwGvkxadIkWfySyjqPd52JhKSyhISksoSEpLKEhKSyhKSyhISksoSEpLKEhKSyhKSyhIRuU7ldu3Zi9UsJCd3C+vXre/bsWaBAgX9TWUJCp2Fubg6V/x/UkHTBYXKtSAAAAABJRU5ErkJggg==\"}]}"},{"id":42461,"title":"This is a palindrome and so am I","description":"A palindrome is a sequence of characters which reads the same backward or forward, for instance\r\n\r\n'a man a plan a canal panama'\r\n\r\nis a palindrome.\r\nWrite a function that, \r\n\r\n*a)* given a string input, returns true or false depending on whether this string is a palindrome (up to white-spaces) or not.\r\n\r\n*b)* The function's source code must be a palindrome.","description_html":"\u003cp\u003eA palindrome is a sequence of characters which reads the same backward or forward, for instance\u003c/p\u003e\u003cp\u003e'a man a plan a canal panama'\u003c/p\u003e\u003cp\u003eis a palindrome.\r\nWrite a function that,\u003c/p\u003e\u003cp\u003e\u003cb\u003ea)\u003c/b\u003e given a string input, returns true or false depending on whether this string is a palindrome (up to white-spaces) or not.\u003c/p\u003e\u003cp\u003e\u003cb\u003eb)\u003c/b\u003e The function's source code must be a palindrome.\u003c/p\u003e","function_template":"function y = is_pal(s)\r\n% )s(lap_si = y noitcnuf\r\n","test_suite":"%%\r\ns = 'a man a plan a canal panama';\r\nassert(isequal(is_pal(s),true))\r\n%%\r\ns = 'taco cat';\r\nassert(isequal(is_pal(s),true))\r\n%%\r\ns = 'a man a plan  canal panama';\r\nassert(isequal(is_pal(s),false))\r\n%%\r\ns = char(randi(74,1,200)+'0');\r\nassert(isequal(is_pal(s),false)); % most probably\r\n%%\r\ns = char(randi(74,1,200)+'0');\r\ns = [s fliplr(s)];\r\nassert(isequal(is_pal(s),true));\r\n%%\r\ns = fileread('is_pal.m');\r\ns = regexprep(s,'%This code written by profile_id.*','')\r\nassert(isequal(is_pal(s),true));","published":true,"deleted":false,"likes_count":8,"comments_count":5,"created_by":203,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":36,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2015-07-23T12:29:59.000Z","updated_at":"2025-12-08T18:25:19.000Z","published_at":"2015-07-23T12:30:16.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eA palindrome is a sequence of characters which reads the same backward or forward, for instance\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e'a man a plan a canal panama'\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eis a palindrome. Write a function that,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003ea)\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e given a string input, returns true or false depending on whether this string is a palindrome (up to white-spaces) or not.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eb)\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e The function's source code must be a palindrome.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":42491,"title":"Quine  : write a quine in MATLAB","description":"Quine is a type of program whose output matches the source code.\r\nSee: \u003chttps://en.wikipedia.org/wiki/Quine_(computing) Quine in Wikipedia\u003e\r\n\r\nSimilar in spirit to, http://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\r\n\r\nNote: last line of MATLAB solution is padded with a comment, so you should remove that in your Quine submission","description_html":"\u003cp\u003eQuine is a type of program whose output matches the source code.\r\nSee: \u003ca href = \"https://en.wikipedia.org/wiki/Quine_(computing)\"\u003eQuine in Wikipedia\u003c/a\u003e\u003c/p\u003e\u003cp\u003eSimilar in spirit to, \u003ca href = \"http://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\"\u003ehttp://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\u003c/a\u003e\u003c/p\u003e\u003cp\u003eNote: last line of MATLAB solution is padded with a comment, so you should remove that in your Quine submission\u003c/p\u003e","function_template":"function data = quine(varargin)   \r\n   % Make me quiny, or else I''m whiny\r\n   data = sprintf('function data = quine(varargin)   ... ')\r\nend\r\n","test_suite":"%% Test for Quine \r\n\r\nnl = char(10);\r\ncontents = strsplit(fileread('quine.m'),nl);\r\nref_contents = [strjoin(contents(1:end-2),nl), nl];\r\nactual_contents=quine();\r\n\r\nassert( isequal(ref_contents,actual_contents) )\r\n","published":true,"deleted":false,"likes_count":3,"comments_count":0,"created_by":3378,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":13,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2015-08-05T20:29:05.000Z","updated_at":"2025-07-28T06:08:46.000Z","published_at":"2015-08-05T20:29:54.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eQuine is a type of program whose output matches the source code. See:\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"https://en.wikipedia.org/wiki/Quine_(computing)\\\"\u003e\u003cw:r\u003e\u003cw:t\u003eQuine in Wikipedia\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSimilar in spirit to,\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"http://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\\\"\u003e\u003cw:r\u003e\u003cw:t\u003ehttp://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eNote: last line of MATLAB solution is padded with a comment, so you should remove that in your Quine submission\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":1190,"title":"Golomb's self-describing sequence (based on Euler 341)","description":"The Golomb's self-describing sequence {G(n)} is the only nondecreasing sequence of natural numbers such that n appears exactly G(n) times in the sequence. The values of G(n) for the first few n are\r\n\r\n* |n =\u0026nbsp;    1    2    3\t4\t5\t6\t7\t8\t9\t10\t11\t12\t13\t14\t15\t…|\r\n* |G(n) 1    2\t2\t3\t3\t4\t4\t4\t5\t5\t\u0026nbsp;5\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;…|\r\n\r\nWrite a MATLAB script that will give you G(n) when given n.\r\n\r\nEfficiency is key here, since some of the values in the test suite will take a while to calculate.","description_html":"\u003cp\u003eThe Golomb's self-describing sequence {G(n)} is the only nondecreasing sequence of natural numbers such that n appears exactly G(n) times in the sequence. The values of G(n) for the first few n are\u003c/p\u003e\u003cul\u003e\u003cli\u003e\u003ctt\u003en =\u0026nbsp;    1    2    3\t4\t5\t6\t7\t8\t9\t10\t11\t12\t13\t14\t15\t…\u003c/tt\u003e\u003c/li\u003e\u003cli\u003e\u003ctt\u003eG(n) 1    2\t2\t3\t3\t4\t4\t4\t5\t5\t\u0026nbsp;5\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;…\u003c/tt\u003e\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eWrite a MATLAB script that will give you G(n) when given n.\u003c/p\u003e\u003cp\u003eEfficiency is key here, since some of the values in the test suite will take a while to calculate.\u003c/p\u003e","function_template":"function y = euler341(x)\r\n  y = x;\r\nend","test_suite":"%%\r\nassert(isequal(euler341(1),1))\r\n%%\r\nassert(isequal(euler341(10),5))\r\n%%\r\nassert(isequal(euler341(310),42))\r\n%%\r\nassert(isequal(euler341(4242),210))\r\n%%\r\nassert(isequal(euler341(328509),3084))\r\n%%\r\nassert(isequal(euler341(551368),4247))\r\n%%\r\nassert(isequal(euler341(614125),4540))\r\n","published":true,"deleted":false,"likes_count":3,"comments_count":0,"created_by":1615,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":183,"test_suite_updated_at":"2013-10-01T17:43:23.000Z","rescore_all_solutions":false,"group_id":27,"created_at":"2013-01-09T15:55:47.000Z","updated_at":"2026-03-25T04:50:04.000Z","published_at":"2013-01-09T15:55:47.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eThe Golomb's self-describing sequence {G(n)} is the only nondecreasing sequence of natural numbers such that n appears exactly G(n) times in the sequence. The values of G(n) for the first few n are\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:rFonts w:cs=\\\"monospace\\\"/\u003e\u003c/w:rPr\u003e\u003cw:t\u003en = 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 …\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:rFonts w:cs=\\\"monospace\\\"/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eG(n) 1 2 2 3 3 4 4 4 5 5 5 6 6 6 6 …\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite a MATLAB script that will give you G(n) when given n.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eEfficiency is key here, since some of the values in the test suite will take a while to calculate.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":2907,"title":"Collaborative Fun : Nomination","description":"Series of problems have been presented in Cody aiming at collaborative fun. This problem is based on Alfonso's problem #2825 - Pay it Forward. This one encourages more directed collaboration.\r\n\r\nYou can solve this problem only if you are nominated by some other player. Once you are nominated, you can solve it by returning anything. You can nominate a player to solve this problem by returning his player ID.\r\n\r\nThis is not a hacking problem. You should hack only when you are not interested in collaboration.\r\n\r\nExample - I have nominated Alfonso by returning his player ID 1379371. (Since test suite of this problem uses codes from his problem, it is fair to nominate Alfonso)","description_html":"\u003cp\u003eSeries of problems have been presented in Cody aiming at collaborative fun. This problem is based on Alfonso's problem #2825 - Pay it Forward. This one encourages more directed collaboration.\u003c/p\u003e\u003cp\u003eYou can solve this problem only if you are nominated by some other player. Once you are nominated, you can solve it by returning anything. You can nominate a player to solve this problem by returning his player ID.\u003c/p\u003e\u003cp\u003eThis is not a hacking problem. You should hack only when you are not interested in collaboration.\u003c/p\u003e\u003cp\u003eExample - I have nominated Alfonso by returning his player ID 1379371. (Since test suite of this problem uses codes from his problem, it is fair to nominate Alfonso)\u003c/p\u003e","function_template":"function y = nomination(x)\r\n  y = ;\r\nend","test_suite":"lines=textread('nomination.m','%s');\r\nid_own=str2num(regexp(lines{end},'\\d+','match','once'));\r\n\r\nx=uint64(nomination());\r\n\r\nif x == uint64(id_own)\r\n    assignin('caller','score',-1);\r\n    error('Funny! You tried to nominate yourself!')\r\nend\r\n\r\nassignin('caller','score',x);\r\n\r\nproblem=2907;\r\nhtml=urlread(sprintf('http://www.mathworks.com/matlabcentral/cody/problems/%d/solutions?term=size:%d',problem,id_own));\r\nn=numel(regexpi(html,'solution \\d+'));\r\n\r\nif n \u003c 1\r\n    error('Sorry. You are nominated by none.');\r\nend\r\n\r\n\r\n%_______\r\n\r\nurl = sprintf('https://www.mathworks.com/matlabcentral/cody/players/%d',x);\r\nhtml = urlread(url);\r\n\r\nc = regexp(html,'h1.+h1','match');\r\nname = c{1}(4:end-4);\r\n\r\ns = sprintf('____________________\\n\\nYou have nominated %s !!!',name);\r\ndisp(s)","published":true,"deleted":false,"likes_count":4,"comments_count":7,"created_by":17203,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":10,"test_suite_updated_at":"2015-02-01T12:49:00.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2015-01-31T09:55:23.000Z","updated_at":"2025-06-22T16:20:35.000Z","published_at":"2015-01-31T09:55:23.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSeries of problems have been presented in Cody aiming at collaborative fun. This problem is based on Alfonso's problem #2825 - Pay it Forward. This one encourages more directed collaboration.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eYou can solve this problem only if you are nominated by some other player. Once you are nominated, you can solve it by returning anything. You can nominate a player to solve this problem by returning his player ID.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eThis is not a hacking problem. You should hack only when you are not interested in collaboration.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eExample - I have nominated Alfonso by returning his player ID 1379371. (Since test suite of this problem uses codes from his problem, it is fair to nominate Alfonso)\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":242,"title":"Make a function that returns its own character count","description":"Write a function that returns a 128 element vector with an accurate inventory of the ASCII characters in its own function file. The test suite uses textscan to verify that your function returns the exact same census.\r\n file = textscan(fid,'%c','CommentStyle','%','Whitespace','')\r\n filetext = file{1};\r\n texthist = histc(filetext,1:128);\r\nNewlines are suppressed by this approach, so you may assume the counts for ASCII 10 and 13 are zero.\r\nSpecial Note: The characters associated with ASCII values 33-41 are not allowed in your function. For clarity, these are\r\n 33 !\r\n 34 \"\r\n 35 #\r\n 36 $\r\n 37 %\r\n 38 \u0026\r\n 39 '\r\n 40 (\r\n 41 )","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.4333px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: rgb(0, 0, 0); white-space: normal; \"\u003e\u003cdiv style=\"block-size: 368.2px; display: block; min-width: 0px; padding-block-start: 0px; padding-top: 0px; perspective-origin: 407px 184.1px; transform-origin: 407px 184.1px; vertical-align: baseline; \"\u003e\u003cdiv style=\"block-size: 42px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 21px; text-align: left; transform-origin: 384px 21px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 375.5px 8px; transform-origin: 375.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eWrite a function that returns a 128 element vector with an accurate inventory of the ASCII characters in its own function file. The test suite uses textscan to verify that your function returns the exact same census.\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgb(247, 247, 247); block-size: 61.3px; border-bottom-left-radius: 4px; border-bottom-right-radius: 4px; border-end-end-radius: 4px; border-end-start-radius: 4px; border-start-end-radius: 4px; border-start-start-radius: 4px; border-top-left-radius: 4px; border-top-right-radius: 4px; margin-block-end: 10px; margin-block-start: 10px; margin-bottom: 10px; margin-inline-end: 3px; margin-inline-start: 3px; margin-left: 3px; margin-right: 3px; margin-top: 10px; perspective-origin: 404px 30.65px; transform-origin: 404px 30.65px; margin-left: 3px; margin-top: 10px; margin-bottom: 10px; margin-right: 3px; \"\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 244px 8.5px; tab-size: 4; transform-origin: 244px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 84px 8.5px; transform-origin: 84px 8.5px; \"\u003e file = textscan(fid,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 16px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 16px 8.5px; \"\u003e'%c'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 56px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 56px 8.5px; \"\u003e'CommentStyle'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 12px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 12px 8.5px; \"\u003e'%'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 48px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 48px 8.5px; \"\u003e'Whitespace'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 8px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 8px 8.5px; \"\u003e''\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e)\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 80px 8.5px; tab-size: 4; transform-origin: 80px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e filetext = file{1};\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 136px 8.5px; tab-size: 4; transform-origin: 136px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e texthist = histc(filetext,1:128);\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 10px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 10px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 10px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 328.5px 8px; transform-origin: 328.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eNewlines are suppressed by this approach, so you may assume the counts for ASCII 10 and 13 are zero.\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 46px 8px; transform-origin: 46px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"font-weight: 700; \"\u003eSpecial Note:\u003c/span\u003e\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 331.5px 8px; transform-origin: 331.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e The characters associated with ASCII values 33-41 are not allowed in your function. For clarity, these are\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgb(247, 247, 247); block-size: 183.9px; border-bottom-left-radius: 4px; border-bottom-right-radius: 4px; border-end-end-radius: 4px; border-end-start-radius: 4px; border-start-end-radius: 4px; border-start-start-radius: 4px; border-top-left-radius: 4px; border-top-right-radius: 4px; margin-block-end: 10px; margin-block-start: 10px; margin-bottom: 10px; margin-inline-end: 3px; margin-inline-start: 3px; margin-left: 3px; margin-right: 3px; margin-top: 10px; perspective-origin: 404px 91.95px; transform-origin: 404px 91.95px; margin-left: 3px; margin-top: 10px; margin-bottom: 10px; margin-right: 3px; \"\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 33 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(178, 140, 0); border-block-start-color: rgb(178, 140, 0); border-bottom-color: rgb(178, 140, 0); border-inline-end-color: rgb(178, 140, 0); border-inline-start-color: rgb(178, 140, 0); border-left-color: rgb(178, 140, 0); border-right-color: rgb(178, 140, 0); border-top-color: rgb(178, 140, 0); caret-color: rgb(178, 140, 0); color: rgb(178, 140, 0); column-rule-color: rgb(178, 140, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(178, 140, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(178, 140, 0); text-emphasis-color: rgb(178, 140, 0); transform-origin: 4px 8.5px; \"\u003e!\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 34 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(196, 0, 0); border-block-start-color: rgb(196, 0, 0); border-bottom-color: rgb(196, 0, 0); border-inline-end-color: rgb(196, 0, 0); border-inline-start-color: rgb(196, 0, 0); border-left-color: rgb(196, 0, 0); border-right-color: rgb(196, 0, 0); border-top-color: rgb(196, 0, 0); caret-color: rgb(196, 0, 0); color: rgb(196, 0, 0); column-rule-color: rgb(196, 0, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(196, 0, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(196, 0, 0); text-emphasis-color: rgb(196, 0, 0); transform-origin: 4px 8.5px; \"\u003e\"\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 35 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(255, 0, 0); border-block-start-color: rgb(255, 0, 0); border-bottom-color: rgb(255, 0, 0); border-inline-end-color: rgb(255, 0, 0); border-inline-start-color: rgb(255, 0, 0); border-left-color: rgb(255, 0, 0); border-right-color: rgb(255, 0, 0); border-top-color: rgb(255, 0, 0); caret-color: rgb(255, 0, 0); color: rgb(255, 0, 0); column-rule-color: rgb(255, 0, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(255, 0, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(255, 0, 0); text-emphasis-color: rgb(255, 0, 0); transform-origin: 4px 8.5px; \"\u003e#\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 36 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(255, 0, 0); border-block-start-color: rgb(255, 0, 0); border-bottom-color: rgb(255, 0, 0); border-inline-end-color: rgb(255, 0, 0); border-inline-start-color: rgb(255, 0, 0); border-left-color: rgb(255, 0, 0); border-right-color: rgb(255, 0, 0); border-top-color: rgb(255, 0, 0); caret-color: rgb(255, 0, 0); color: rgb(255, 0, 0); column-rule-color: rgb(255, 0, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(255, 0, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(255, 0, 0); text-emphasis-color: rgb(255, 0, 0); transform-origin: 4px 8.5px; \"\u003e$\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 37 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(2, 128, 9); border-block-start-color: rgb(2, 128, 9); border-bottom-color: rgb(2, 128, 9); border-inline-end-color: rgb(2, 128, 9); border-inline-start-color: rgb(2, 128, 9); border-left-color: rgb(2, 128, 9); border-right-color: rgb(2, 128, 9); border-top-color: rgb(2, 128, 9); caret-color: rgb(2, 128, 9); color: rgb(2, 128, 9); column-rule-color: rgb(2, 128, 9); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(2, 128, 9); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(2, 128, 9); text-emphasis-color: rgb(2, 128, 9); transform-origin: 4px 8.5px; \"\u003e%\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e 38 \u0026amp;\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 39 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(196, 0, 0); border-block-start-color: rgb(196, 0, 0); border-bottom-color: rgb(196, 0, 0); border-inline-end-color: rgb(196, 0, 0); border-inline-start-color: rgb(196, 0, 0); border-left-color: rgb(196, 0, 0); border-right-color: rgb(196, 0, 0); border-top-color: rgb(196, 0, 0); caret-color: rgb(196, 0, 0); color: rgb(196, 0, 0); column-rule-color: rgb(196, 0, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(196, 0, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(196, 0, 0); text-emphasis-color: rgb(196, 0, 0); transform-origin: 4px 8.5px; \"\u003e'\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e 40 (\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e 41 )\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function x = omphaloskeptic\r\n  x = 0;\r\nend","test_suite":"%%\r\nfname = 'omphaloskeptic.m';\r\nfid = fopen(fname);\r\nfile = textscan(fid,'%c', ...\r\n  'CommentStyle','%', ...\r\n  'Whitespace','');\r\nfclose(fid);\r\n\r\nha = histc(file{1},1:128);\r\nhp = omphaloskeptic;\r\n\r\nassert(~any(ismember(33:41,find(ha))),'Used an illegal character');\r\nassert(isequal(ha,hp),'Actual characters did not match prediction');","published":true,"deleted":false,"likes_count":4,"comments_count":1,"created_by":7,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":34,"test_suite_updated_at":"2021-09-07T15:14:16.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2012-02-02T22:19:52.000Z","updated_at":"2026-03-21T04:10:51.000Z","published_at":"2012-02-03T15:28:39.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite a function that returns a 128 element vector with an accurate inventory of the ASCII characters in its own function file. The test suite uses textscan to verify that your function returns the exact same census.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ file = textscan(fid,'%c','CommentStyle','%','Whitespace','')\\n filetext = file{1};\\n texthist = histc(filetext,1:128);]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eNewlines are suppressed by this approach, so you may assume the counts for ASCII 10 and 13 are zero.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eSpecial Note:\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e The characters associated with ASCII values 33-41 are not allowed in your function. For clarity, these are\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ 33 !\\n 34 \\\"\\n 35 #\\n 36 $\\n 37 %\\n 38 \u0026\\n 39 '\\n 40 (\\n 41 )]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":43676,"title":"Count the Digits in the Box","description":"In this problem you must provide an accurate census of all the digits inside a given box. The problem is complicated by the fact that your census report also appears inside the box, thereby influencing the result. Here is the simplest form of the problem.\r\n\r\n ----------------------------------------------\r\n |  The number of 0's inside the box is: ___  |\r\n |  The number of 1's inside the box is: ___  |\r\n |  The number of 2's inside the box is: ___  |\r\n |  The number of 3's inside the box is: ___  |\r\n |  The number of 4's inside the box is: ___  |\r\n |  The number of 5's inside the box is: ___  |\r\n |  The number of 6's inside the box is: ___  |\r\n |  The number of 7's inside the box is: ___  |\r\n |  The number of 8's inside the box is: ___  |\r\n |  The number of 9's inside the box is: ___  |\r\n ----------------------------------------------\r\n\r\nSuppose you start to fill it in like this: there's only one 2, so you put a 1 next to the 2. But there are now two 1's, so you put a 2 next to the 1. But now there are three 2's... and so on. This problem eventually converges and can be answered as follows.\r\n\r\n --------------------------------------------\r\n | The number of 0's inside the box is:   1 |\r\n | The number of 1's inside the box is:   7 |\r\n | The number of 2's inside the box is:   3 |\r\n | The number of 3's inside the box is:   2 |\r\n | The number of 4's inside the box is:   1 |\r\n | The number of 5's inside the box is:   1 |\r\n | The number of 6's inside the box is:   1 |\r\n | The number of 7's inside the box is:   2 |\r\n | The number of 8's inside the box is:   1 |\r\n | The number of 9's inside the box is:   1 |\r\n --------------------------------------------\r\n\r\nCount the numbers and you'll see the sums all work out. We will complicate this problem by adding some extra numbers to the top of the box. \r\n\r\n*Example*\r\n\r\nIf\r\n\r\n extras = 22222\r\n\r\nthen we can see by inspection that one solution is\r\n\r\n census = [1 7 7 2 1 1 1 3 1 1]\r\n\r\nas shown below\r\n\r\n --------------------------------------------\r\n | Here are some extra numbers:       22222 |\r\n | The number of 0's inside the box is:   1 |\r\n | The number of 1's inside the box is:   7 |\r\n | The number of 2's inside the box is:   7 |\r\n | The number of 3's inside the box is:   2 |\r\n | The number of 4's inside the box is:   1 |\r\n | The number of 5's inside the box is:   1 |\r\n | The number of 6's inside the box is:   1 |\r\n | The number of 7's inside the box is:   3 |\r\n | The number of 8's inside the box is:   1 |\r\n | The number of 9's inside the box is:   1 |\r\n --------------------------------------------\r\n\r\nIn general, your answer might not be unique. We'll just test whether you meet the criteria.","description_html":"\u003cp\u003eIn this problem you must provide an accurate census of all the digits inside a given box. The problem is complicated by the fact that your census report also appears inside the box, thereby influencing the result. Here is the simplest form of the problem.\u003c/p\u003e\u003cpre\u003e ----------------------------------------------\r\n |  The number of 0's inside the box is: ___  |\r\n |  The number of 1's inside the box is: ___  |\r\n |  The number of 2's inside the box is: ___  |\r\n |  The number of 3's inside the box is: ___  |\r\n |  The number of 4's inside the box is: ___  |\r\n |  The number of 5's inside the box is: ___  |\r\n |  The number of 6's inside the box is: ___  |\r\n |  The number of 7's inside the box is: ___  |\r\n |  The number of 8's inside the box is: ___  |\r\n |  The number of 9's inside the box is: ___  |\r\n ----------------------------------------------\u003c/pre\u003e\u003cp\u003eSuppose you start to fill it in like this: there's only one 2, so you put a 1 next to the 2. But there are now two 1's, so you put a 2 next to the 1. But now there are three 2's... and so on. This problem eventually converges and can be answered as follows.\u003c/p\u003e\u003cpre\u003e --------------------------------------------\r\n | The number of 0's inside the box is:   1 |\r\n | The number of 1's inside the box is:   7 |\r\n | The number of 2's inside the box is:   3 |\r\n | The number of 3's inside the box is:   2 |\r\n | The number of 4's inside the box is:   1 |\r\n | The number of 5's inside the box is:   1 |\r\n | The number of 6's inside the box is:   1 |\r\n | The number of 7's inside the box is:   2 |\r\n | The number of 8's inside the box is:   1 |\r\n | The number of 9's inside the box is:   1 |\r\n --------------------------------------------\u003c/pre\u003e\u003cp\u003eCount the numbers and you'll see the sums all work out. We will complicate this problem by adding some extra numbers to the top of the box.\u003c/p\u003e\u003cp\u003e\u003cb\u003eExample\u003c/b\u003e\u003c/p\u003e\u003cp\u003eIf\u003c/p\u003e\u003cpre\u003e extras = 22222\u003c/pre\u003e\u003cp\u003ethen we can see by inspection that one solution is\u003c/p\u003e\u003cpre\u003e census = [1 7 7 2 1 1 1 3 1 1]\u003c/pre\u003e\u003cp\u003eas shown below\u003c/p\u003e\u003cpre\u003e --------------------------------------------\r\n | Here are some extra numbers:       22222 |\r\n | The number of 0's inside the box is:   1 |\r\n | The number of 1's inside the box is:   7 |\r\n | The number of 2's inside the box is:   7 |\r\n | The number of 3's inside the box is:   2 |\r\n | The number of 4's inside the box is:   1 |\r\n | The number of 5's inside the box is:   1 |\r\n | The number of 6's inside the box is:   1 |\r\n | The number of 7's inside the box is:   3 |\r\n | The number of 8's inside the box is:   1 |\r\n | The number of 9's inside the box is:   1 |\r\n --------------------------------------------\u003c/pre\u003e\u003cp\u003eIn general, your answer might not be unique. We'll just test whether you meet the criteria.\u003c/p\u003e","function_template":"function census = getDigitCensus(extras)\r\n  census = [0 0 0 0 0 0 0 0 0 0];\r\nend","test_suite":"%%\r\nextras = 22222;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 6380059;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 99999432;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 347879;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 83870955;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 1111111111;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))","published":true,"deleted":false,"likes_count":3,"comments_count":4,"created_by":7,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":6,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2016-11-21T20:00:30.000Z","updated_at":"2016-12-14T15:19:55.000Z","published_at":"2016-12-13T23:01:52.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eIn this problem you must provide an accurate census of all the digits inside a given box. The problem is complicated by the fact that your census report also appears inside the box, thereby influencing the result. Here is the simplest form of the problem.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ ----------------------------------------------\\n |  The number of 0's inside the box is: ___  |\\n |  The number of 1's inside the box is: ___  |\\n |  The number of 2's inside the box is: ___  |\\n |  The number of 3's inside the box is: ___  |\\n |  The number of 4's inside the box is: ___  |\\n |  The number of 5's inside the box is: ___  |\\n |  The number of 6's inside the box is: ___  |\\n |  The number of 7's inside the box is: ___  |\\n |  The number of 8's inside the box is: ___  |\\n |  The number of 9's inside the box is: ___  |\\n ----------------------------------------------]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSuppose you start to fill it in like this: there's only one 2, so you put a 1 next to the 2. But there are now two 1's, so you put a 2 next to the 1. But now there are three 2's... and so on. This problem eventually converges and can be answered as follows.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ --------------------------------------------\\n | The number of 0's inside the box is:   1 |\\n | The number of 1's inside the box is:   7 |\\n | The number of 2's inside the box is:   3 |\\n | The number of 3's inside the box is:   2 |\\n | The number of 4's inside the box is:   1 |\\n | The number of 5's inside the box is:   1 |\\n | The number of 6's inside the box is:   1 |\\n | The number of 7's inside the box is:   2 |\\n | The number of 8's inside the box is:   1 |\\n | The number of 9's inside the box is:   1 |\\n --------------------------------------------]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eCount the numbers and you'll see the sums all work out. We will complicate this problem by adding some extra numbers to the top of the box.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eExample\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eIf\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ extras = 22222]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003ethen we can see by inspection that one solution is\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ census = [1 7 7 2 1 1 1 3 1 1]]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eas shown below\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ --------------------------------------------\\n | Here are some extra numbers:       22222 |\\n | The number of 0's inside the box is:   1 |\\n | The number of 1's inside the box is:   7 |\\n | The number of 2's inside the box is:   7 |\\n | The number of 3's inside the box is:   2 |\\n | The number of 4's inside the box is:   1 |\\n | The number of 5's inside the box is:   1 |\\n | The number of 6's inside the box is:   1 |\\n | The number of 7's inside the box is:   3 |\\n | The number of 8's inside the box is:   1 |\\n | The number of 9's inside the box is:   1 |\\n --------------------------------------------]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eIn general, your answer might not be unique. We'll just test whether you meet the criteria.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"}],"problem_search":{"errors":[],"problems":[{"id":2313,"title":"Narcissistic problem","description":"How many likes has this problem?","description_html":"\u003cp\u003eHow many likes has this problem?\u003c/p\u003e","function_template":"function y = like_me(x)\r\n  y = x;\r\nend","test_suite":"%%\r\n% this problem will be updated,\r\n% your score/size can change over time\r\n% if you submit a fixed value :-)\r\n%%\r\ny=like_me();\r\nassert(isequal(mod(y,1),0));\r\n%%\r\ny=like_me();\r\nassert(y\u003e0);\r\n%%\r\ny=like_me();\r\nurl='http://www.mathworks.co.uk/matlabcentral/cody/problems/2313'\r\n% the main problem with this problem is that ...\r\n% this problem thinks.\r\n% it thinks about itself most of the time.\r\n% it is convinced, that at least X likes has it.\r\ny_sub_correct=max([10 cellfun(@(S)str2num(cell2mat(S)),regexp(urlread(url),'(\\d*) players\u003c/a\u003e like this problem','tokens'))]); % probably hackable by comments?\r\nt = mtree('like_me.m','-file');\r\nsize = length(t.nodesize);\r\n% this problem likes compliments,\r\n% even false.\r\n% For good compliment it is going to pass your solution with a smaller size! \r\n% But if you don't appreciate it, it can punish you...\r\nfeval(@assignin,'caller','score',round(max(0,size*(.5+.5*y_sub_correct/y))));\r\n","published":true,"deleted":false,"likes_count":30,"comments_count":4,"created_by":14358,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":166,"test_suite_updated_at":"2014-12-05T16:31:19.000Z","rescore_all_solutions":true,"group_id":1,"created_at":"2014-05-08T09:18:27.000Z","updated_at":"2026-02-14T16:20:13.000Z","published_at":"2014-05-08T09:25:53.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eHow many likes has this problem?\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":2312,"title":"How many solutions has this problem?","description":"Guess, predict or calculate :-)\r\n\r\n(You will be scored by the accuracy).\r\n\r\n\r\n\r\n\r\nUpdate: \u003chttp://www.mathworks.co.uk/matlabcentral/about/trendy/ TRENDY\u003e \u003chttp://www.mathworks.co.uk/matlabcentral/trendy/Tutorial/urlfilter.html is\u003e here!","description_html":"\u003cp\u003eGuess, predict or calculate :-)\u003c/p\u003e\u003cp\u003e(You will be scored by the accuracy).\u003c/p\u003e\u003cp\u003eUpdate: \u003ca href = \"http://www.mathworks.co.uk/matlabcentral/about/trendy/\"\u003eTRENDY\u003c/a\u003e \u003ca href = \"http://www.mathworks.co.uk/matlabcentral/trendy/Tutorial/urlfilter.html\"\u003eis\u003c/a\u003e here!\u003c/p\u003e","function_template":"function y = solutions(x)\r\n  y = 42;\r\nend","test_suite":"%%\r\n% please ''ignore'' this first test, this code is here to put function \r\n% urlfilter known from matlabcentral/trendy to the path for this problem\r\n% (method taken from Doug's Hull problem Steal, Share, or Catch)\r\nfh=fopen('urlfilter.m','wt');\r\nfprintf(fh, '%s \\n', 'function out = urlfilter(url, target, numNumbers, direction)') ;\r\nfprintf(fh, '%s \\n', '  if nargin \u003c 3, numNumbers = 1; end');\r\nfprintf(fh, '%s \\n', '  if nargin \u003c 4 direction = ''forward''; end');\r\nfprintf(fh, '%s \\n', '  % If url is not an actual URL, then treat it as a string');\r\nfprintf(fh, '%s \\n', '  if strcmp(url(1:4),''http''), textStr = urlread(url); else textStr = url; end');\r\nfprintf(fh, '%s \\n', '  % Handle special case where two numbers are given as part of a range');\r\nfprintf(fh, '%s \\n', '  %   Example: \"annual rainfall = 20-40 inches\"');\r\nfprintf(fh, '%s \\n', '  % Solution is a pre-processing step that replaces the dash with a space');\r\nfprintf(fh, '%s \\n', '  %   Example: \"annual rainfall = 20 40 inches\"');\r\nfprintf(fh, '%s \\n', '  textStr = regexprep(textStr,''(\\d+)-(\\d+)'',''$1 $2'');');\r\nfprintf(fh, '%s \\n', '  strIndex = strfind(textStr,target);');\r\nfprintf(fh, '%s \\n', '  if isempty(strIndex),');\r\nfprintf(fh, '%s \\n', '    error( ''trendy:urlfilter:TargetStringNotFound'', ...');\r\nfprintf(fh, '%s \\n', '          [''Target string '' target '' does not appear''])');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', '  % Start looking after the first appearance of the target');\r\nfprintf(fh, '%s \\n', '  if strcmp(direction,''forward'')');\r\nfprintf(fh, '%s \\n', '    strIndex = strIndex(1) + length(target);');\r\nfprintf(fh, '%s \\n', '  elseif strcmp(direction,''backward'')');\r\nfprintf(fh, '%s \\n', '    strIndex = strIndex(1) - 1;');\r\nfprintf(fh, '%s \\n', '  else');\r\nfprintf(fh, '%s \\n', '    error( ''trendy:urlfilter:InvalidDirectionFlag'', ...');\r\nfprintf(fh, '%s \\n', '           ''DIRECTION must be either ''''forward'''' or ''''backward''''.'' );');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', '  out = zeros(1,numNumbers);');\r\nfprintf(fh, '%s \\n', '  for i = 1:numNumbers');\r\nfprintf(fh, '%s \\n', '    [out(i),strIndex] = getNextNumber(textStr,strIndex,direction);');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', 'end');\r\nfprintf(fh, '%s \\n', '% =========================');\r\nfprintf(fh, '%s \\n', 'function [nextNumber,strIndex] = getNextNumber(textStr,strIndex,direction)');\r\nfprintf(fh, '%s \\n', '  % Use a state machine to sift through the HTML for numbers.');\r\nfprintf(fh, '%s \\n', '  if strcmp(direction,''forward'')');\r\nfprintf(fh, '%s \\n', '    openTagSymbol  = ''\u003c'';');\r\nfprintf(fh, '%s \\n', '    closeTagSymbol = ''\u003e'';');\r\nfprintf(fh, '%s \\n', '    moveIndexFcn   = @(x) x+1;');\r\nfprintf(fh, '%s \\n', '    concatenateFcn = @(a,b) [a b];');\r\nfprintf(fh, '%s \\n', '  else');\r\nfprintf(fh, '%s \\n', '    openTagSymbol  = ''\u003e'';');\r\nfprintf(fh, '%s \\n', '    closeTagSymbol = ''\u003c'';');\r\nfprintf(fh, '%s \\n', '    moveIndexFcn   = @(x) x-1;');\r\nfprintf(fh, '%s \\n', '    concatenateFcn = @(a,b) [b a];');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', '  urlStrLen = length(textStr);');\r\nfprintf(fh, '%s \\n', '  state = ''notnumber'';');\r\nfprintf(fh, '%s \\n', '  while true');\r\nfprintf(fh, '%s \\n', '    ch = textStr(strIndex);');\r\nfprintf(fh, '%s \\n', '    switch state');\r\nfprintf(fh, '%s \\n', '      case ''notnumber''');\r\nfprintf(fh, '%s \\n', '        if isDigitDotDashOrComma(ch)');\r\nfprintf(fh, '%s \\n', '          state = ''number'';');\r\nfprintf(fh, '%s \\n', '          numStr = ch;');\r\nfprintf(fh, '%s \\n', '        elseif (ch == openTagSymbol)');\r\nfprintf(fh, '%s \\n', '          state = ''tagbody'';');\r\nfprintf(fh, '%s \\n', '        end');\r\nfprintf(fh, '%s \\n', '      case ''tagbody''');\r\nfprintf(fh, '%s \\n', '        % Throw away anything inside the tag markup area');\r\nfprintf(fh, '%s \\n', '        if (ch == closeTagSymbol)');\r\nfprintf(fh, '%s \\n', '          state = ''notnumber'';');\r\nfprintf(fh, '%s \\n', '        end ');\r\nfprintf(fh, '%s \\n', '      case ''number''');\r\nfprintf(fh, '%s \\n', '        if isDigitDotDashOrComma(ch)');\r\nfprintf(fh, '%s \\n', '          numStr = concatenateFcn(numStr,ch);');\r\nfprintf(fh, '%s \\n', '        else');\r\nfprintf(fh, '%s \\n', '          % We are transitioning out of a number.');\r\nfprintf(fh, '%s \\n', '          % Note that STR2DOUBLE handles commas in the string.');\r\nfprintf(fh, '%s \\n', '          nextNumber = str2double(numStr);');\r\nfprintf(fh, '%s \\n', '          if ~isnan(nextNumber)');\r\nfprintf(fh, '%s \\n', '            % The number is valid. We''re all done.');\r\nfprintf(fh, '%s \\n', '            break');\r\nfprintf(fh, '%s \\n', '          else');\r\nfprintf(fh, '%s \\n', '            % The number is bogus. Throw it away and continue.');\r\nfprintf(fh, '%s \\n', '            if (ch == openTagSymbol), state = ''tagbody''; else state = ''notnumber''; end');\r\nfprintf(fh, '%s \\n', '          end');\r\nfprintf(fh, '%s \\n', '        end');\r\nfprintf(fh, '%s \\n', '      otherwise');\r\nfprintf(fh, '%s \\n', '        error( ''trendy:urlfilter:InvalidState'', ...');\r\nfprintf(fh, '%s \\n', '             [''Encountered unknown state '' state])');\r\nfprintf(fh, '%s \\n', '    end');\r\nfprintf(fh, '%s \\n', '    strIndex = moveIndexFcn(strIndex);');\r\nfprintf(fh, '%s \\n', '    if (strIndex == 0) || (strIndex \u003e urlStrLen)');\r\nfprintf(fh, '%s \\n', '      % We ran off the end of the string.');\r\nfprintf(fh, '%s \\n', '      disp(''End of file reached.'')');\r\nfprintf(fh, '%s \\n', '      break');\r\nfprintf(fh, '%s \\n', '    end');\r\nfprintf(fh, '%s \\n', '  end');\r\nfprintf(fh, '%s \\n', 'end');\r\nfprintf(fh, '%s \\n', '% ==================');\r\nfprintf(fh, '%s \\n', 'function tf = isDigitDotDashOrComma(ch)');\r\nfprintf(fh, '%s \\n', '  tf = ((ch \u003e= ''0'') \u0026\u0026 (ch \u003c= ''9'')) || ...');\r\nfprintf(fh, '%s \\n', '          (ch == ''.'') || (ch == ''-'') || (ch == '','');');\r\nfprintf(fh, '%s \\n', 'end');\r\nfclose(fh);\r\n%%\r\nrehash path\r\n%%\r\ny=solutions();\r\nassert(isequal(mod(y,1),0))\r\n%%\r\ny=solutions();\r\nassert(y\u003e0);\r\n%%\r\ny=solutions();\r\n% yes, yes solution hidden in the test suite... try to code adifferent one! :-)\r\nurl='http://www.mathworks.co.uk/matlabcentral/cody/problems/2312'\r\ny_correct=max([0 cellfun(@(S)str2num(cell2mat(S)),regexp(urlread(url),'\u003cspan class=\"solution_statistic\"\u003e(\\d*)\u003c/span\u003e\u003cspan class=\"text\"\u003e Solutions\u003c/span\u003e','tokens'))]) + 1; % don't forget your solution\r\nt = mtree('solutions.m','-file');\r\nsize = ceil(length(t.nodesize)/13);\r\nfeval(@assignin,'caller','score',abs(y-y_correct)+size);\r\n% (... and solutions will be rescored from time to time :-D)\r\n","published":true,"deleted":false,"likes_count":2,"comments_count":1,"created_by":14358,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":68,"test_suite_updated_at":"2014-05-12T12:02:31.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2014-05-08T08:33:51.000Z","updated_at":"2026-02-18T14:23:20.000Z","published_at":"2014-05-08T09:06:48.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eGuess, predict or calculate :-)\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e(You will be scored by the accuracy).\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eUpdate:\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"http://www.mathworks.co.uk/matlabcentral/about/trendy/\\\"\u003e\u003cw:r\u003e\u003cw:t\u003eTRENDY\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"http://www.mathworks.co.uk/matlabcentral/trendy/Tutorial/urlfilter.html\\\"\u003e\u003cw:r\u003e\u003cw:t\u003eis\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003cw:r\u003e\u003cw:t\u003e here!\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":1969,"title":"Self-Description","description":"This is a simplified version of the \u003chttp://xkcd.com/688/ *xkcd comic* by the same name\u003e.\r\n\r\nSimply return the angle (in degrees) of the 'black' sector of the pie chart that would make the graph description accurate. \r\n\r\n\u003c\u003chttp://www.alfnie.com/software/self_description02.png\u003e\u003e\r\n\r\n*Details:*\r\n\r\nAssume that the pie chart circle covers 36% of the total image area, and that the text, textbox lines, image frame, and outer circumference of the pie (anything painted in black except the pie chart 'black' sector) add up to 6.4% of the total image area. \r\n\r\nReturn the angle in degrees rounded to 4 decimals. \r\n\r\n_(\"detail oriented\" players may also assume that the portion of the textbox line which is white (overlapping the pie chart 'black' sector) has already been discounted twice from the 6.4% value above)_","description_html":"\u003cp\u003eThis is a simplified version of the \u003ca href = \"http://xkcd.com/688/\"\u003e\u003cb\u003exkcd comic\u003c/b\u003e by the same name\u003c/a\u003e.\u003c/p\u003e\u003cp\u003eSimply return the angle (in degrees) of the 'black' sector of the pie chart that would make the graph description accurate.\u003c/p\u003e\u003cimg src = \"http://www.alfnie.com/software/self_description02.png\"\u003e\u003cp\u003e\u003cb\u003eDetails:\u003c/b\u003e\u003c/p\u003e\u003cp\u003eAssume that the pie chart circle covers 36% of the total image area, and that the text, textbox lines, image frame, and outer circumference of the pie (anything painted in black except the pie chart 'black' sector) add up to 6.4% of the total image area.\u003c/p\u003e\u003cp\u003eReturn the angle in degrees rounded to 4 decimals.\u003c/p\u003e\u003cp\u003e\u003ci\u003e(\"detail oriented\" players may also assume that the portion of the textbox line which is white (overlapping the pie chart 'black' sector) has already been discounted twice from the 6.4% value above)\u003c/i\u003e\u003c/p\u003e","function_template":"function y = piechartangle()\r\n  y = 0;\r\nend","test_suite":"%%\r\nx=piechartangle();\r\nfh=fopen('piechartsolve.p','wb');\r\nfwrite(fh,[118 48 48 46 48 48 118 48 48 46 48 48 0 11 128 28 125 74 255 181 0 0 0 25 0 0 0 78 0 0 0 92 156 161 5 75 80 198 68 25 192 231 52 174 146 57 247 190 205 171 201 55 20 32 41 236 44 207 69 16 38 248 227 160 126 226 43 179 24 228 144 238 252 176 180 231 39 58 57 58 199 133 221 150 59 133 10 11 178 192 106 190 200 24 28 65 163 222 66 234 89 229 14 65 91 62 9 219 22 159],'uchar');\r\nfclose(fh);\r\nrehash;\r\nassert(piechartsolve(x));\r\n","published":true,"deleted":false,"likes_count":4,"comments_count":6,"created_by":43,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":29,"test_suite_updated_at":"2013-11-02T07:06:04.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2013-11-02T06:34:57.000Z","updated_at":"2025-12-30T14:06:23.000Z","published_at":"2013-11-02T07:06:04.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/image\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/media/image1.png\"}],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eThis is a simplified version of the\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"http://xkcd.com/688/\\\"\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003exkcd comic\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e by the same name\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003cw:r\u003e\u003cw:t\u003e.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSimply return the angle (in degrees) of the 'black' sector of the pie chart that would make the graph description accurate.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:customXml w:element=\\\"image\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"height\\\" w:val=\\\"-1\\\"/\u003e\u003cw:attr w:name=\\\"width\\\" w:val=\\\"-1\\\"/\u003e\u003cw:attr w:name=\\\"relationshipId\\\" w:val=\\\"rId1\\\"/\u003e\u003c/w:customXmlPr\u003e\u003c/w:customXml\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eDetails:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eAssume that the pie chart circle covers 36% of the total image area, and that the text, textbox lines, image frame, and outer circumference of the pie (anything painted in black except the pie chart 'black' sector) add up to 6.4% of the total image area.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eReturn the angle in degrees rounded to 4 decimals.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:i/\u003e\u003c/w:rPr\u003e\u003cw:t\u003e(\\\"detail oriented\\\" players may also assume that the portion of the textbox line which is white (overlapping the pie chart 'black' sector) has already been discounted twice from the 6.4% value above)\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"},{\"partUri\":\"/media/image1.png\",\"contentType\":\"image/png\",\"content\":\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAO4AAAC0CAIAAAAcmYfkAAArA0lEQVR42u2deVzP2f7HC1GTpSyFUhSyJAyKrFmzU7Jl3xJjG8tYZ362sQ7ZxnLt1GCmsSeUfWkMUo2tMK4RDcPMpBgG/Z63c+/nfm+S+vatvst5/dHj8/302c45r/N+v95nNTKSkNBxmJub//Of//zXUbNmzebPn/9/EhK6hnnz5nXo0MHExOTfVOZUioSEbuIf//gHHJZUlpBUlpCQVJaQkFSWkJBUlpBUlpCQVJaQkFSWkMgJKv/222/Tp0/fuXPngwcP/v77b87cvXt3//79gYGBJ0+efP36dQb3xsfHh4eH//7778qZv/766+XLl5n5yj///HPq1Klcn8E1vJ2nvXr1iuM3qZClK6n8Xvzwww9cVrRoUUtLywoVKtSsWbN48eLOzs5NmjQpXbr00KFDxWUhISHjxo27d++ecuPnn3/OBdzSvn371atXd+vWrWHDhtxYo0aNH3/8UVyzdu3aDRs2KBQ8c+bM9evXxfHPP/9cqVKlhIQE1Y/ZvHlz3759qUIccyVPK1++PJdVq1bN3t7++++/l6UrqfxeREVFwchbt25xcODAgSFDhnDX6dOn+Rfm1tbWFmI9e/asSp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bsLmoBTfzy5cvq1avb29sTshQtWlQ0SSLgli5d2rVrVzQcTk25EU5zwbRp08aMGdOkSROorLqoo6CyoGyPHj3e3Y8R0y4WjlEGoPETjcgBtQhyX7lyhePhw4dze6VKlVQHfnh4eGDme/XqJYtcUvm/wJFBRBiMlrh8+bKTkxN2dPr06WJtAOJxYo7FixdjFyGlIgkA1/BfeIZxHTRoEJpbddh+WFgYYiAlddgKVtnR0XHixImqbSPcyBOIO2fMmEE1wLfWq1cP4y2qgVjMivPISjc3N4y0avQp1mTgq2SRSyr/F2JVNRiMs4Y3+O7mzZuLBVlw5RCUOBoB16xZM0K0M2fOKDf269cPyyqOz58/j+FUnTWEaHF2dk75z+wS/uXi4qK6ExYaRvmJ/itWrBiuAEGZktrLCI83btyIIB46dCivhs1KPUHZlyxZkq9F7QjLLSGp/C88efLE0tISk8nxgAEDoBcGVaxlAbDWISEhMPizzz6DyhhgrOzRo0eRJZBMCfsuXbpkZ2enOsBq165dQo1w5dRUYGKVJbZSUlcJwRvcu3ePYJEwH0VRqlQpwqCEhATqEkRXGjqGDRuGZB81alRK6tA8BwcHUhceHu7n56e6bJeEoVMZICEgkLCgaYIzuIVVVjQDpMcWYjJRz0SBStsZKhnbGR8fr9z422+/ifpw6NAhRDAKIc3ejLGxsSgZ7CsMtrGxOXny5MqVK/lsjk1MTJQVko4cORIaGsoXwnVEfIkSJaZMmRIcHBwVFZWSupyhWPBOLxukJJVzsOMayt66dUtVEytITEzMauM81Qar/Msvv4hxC69evTp48CBndu7cefjw4Xe9R1BQkFjlSBVwGvkxadIkWfySyjqPd52JhKSyhISksoSEpLKEhKSyhKSyhISksoSEpLKEhKSyhKSyhIRuU7ldu3Zi9UsJCd3C+vXre/bsWaBAgX9TWUJCp2Fubg6V/x/UkHTBYXKtSAAAAABJRU5ErkJggg==\"}]}"},{"id":42461,"title":"This is a palindrome and so am I","description":"A palindrome is a sequence of characters which reads the same backward or forward, for instance\r\n\r\n'a man a plan a canal panama'\r\n\r\nis a palindrome.\r\nWrite a function that, \r\n\r\n*a)* given a string input, returns true or false depending on whether this string is a palindrome (up to white-spaces) or not.\r\n\r\n*b)* The function's source code must be a palindrome.","description_html":"\u003cp\u003eA palindrome is a sequence of characters which reads the same backward or forward, for instance\u003c/p\u003e\u003cp\u003e'a man a plan a canal panama'\u003c/p\u003e\u003cp\u003eis a palindrome.\r\nWrite a function that,\u003c/p\u003e\u003cp\u003e\u003cb\u003ea)\u003c/b\u003e given a string input, returns true or false depending on whether this string is a palindrome (up to white-spaces) or not.\u003c/p\u003e\u003cp\u003e\u003cb\u003eb)\u003c/b\u003e The function's source code must be a palindrome.\u003c/p\u003e","function_template":"function y = is_pal(s)\r\n% )s(lap_si = y noitcnuf\r\n","test_suite":"%%\r\ns = 'a man a plan a canal panama';\r\nassert(isequal(is_pal(s),true))\r\n%%\r\ns = 'taco cat';\r\nassert(isequal(is_pal(s),true))\r\n%%\r\ns = 'a man a plan  canal panama';\r\nassert(isequal(is_pal(s),false))\r\n%%\r\ns = char(randi(74,1,200)+'0');\r\nassert(isequal(is_pal(s),false)); % most probably\r\n%%\r\ns = char(randi(74,1,200)+'0');\r\ns = [s fliplr(s)];\r\nassert(isequal(is_pal(s),true));\r\n%%\r\ns = fileread('is_pal.m');\r\ns = regexprep(s,'%This code written by profile_id.*','')\r\nassert(isequal(is_pal(s),true));","published":true,"deleted":false,"likes_count":8,"comments_count":5,"created_by":203,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":36,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2015-07-23T12:29:59.000Z","updated_at":"2025-12-08T18:25:19.000Z","published_at":"2015-07-23T12:30:16.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eA palindrome is a sequence of characters which reads the same backward or forward, for instance\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e'a man a plan a canal panama'\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eis a palindrome. Write a function that,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003ea)\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e given a string input, returns true or false depending on whether this string is a palindrome (up to white-spaces) or not.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eb)\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e The function's source code must be a palindrome.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":42491,"title":"Quine  : write a quine in MATLAB","description":"Quine is a type of program whose output matches the source code.\r\nSee: \u003chttps://en.wikipedia.org/wiki/Quine_(computing) Quine in Wikipedia\u003e\r\n\r\nSimilar in spirit to, http://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\r\n\r\nNote: last line of MATLAB solution is padded with a comment, so you should remove that in your Quine submission","description_html":"\u003cp\u003eQuine is a type of program whose output matches the source code.\r\nSee: \u003ca href = \"https://en.wikipedia.org/wiki/Quine_(computing)\"\u003eQuine in Wikipedia\u003c/a\u003e\u003c/p\u003e\u003cp\u003eSimilar in spirit to, \u003ca href = \"http://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\"\u003ehttp://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\u003c/a\u003e\u003c/p\u003e\u003cp\u003eNote: last line of MATLAB solution is padded with a comment, so you should remove that in your Quine submission\u003c/p\u003e","function_template":"function data = quine(varargin)   \r\n   % Make me quiny, or else I''m whiny\r\n   data = sprintf('function data = quine(varargin)   ... ')\r\nend\r\n","test_suite":"%% Test for Quine \r\n\r\nnl = char(10);\r\ncontents = strsplit(fileread('quine.m'),nl);\r\nref_contents = [strjoin(contents(1:end-2),nl), nl];\r\nactual_contents=quine();\r\n\r\nassert( isequal(ref_contents,actual_contents) )\r\n","published":true,"deleted":false,"likes_count":3,"comments_count":0,"created_by":3378,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":13,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2015-08-05T20:29:05.000Z","updated_at":"2025-07-28T06:08:46.000Z","published_at":"2015-08-05T20:29:54.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eQuine is a type of program whose output matches the source code. See:\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"https://en.wikipedia.org/wiki/Quine_(computing)\\\"\u003e\u003cw:r\u003e\u003cw:t\u003eQuine in Wikipedia\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSimilar in spirit to,\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"http://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\\\"\u003e\u003cw:r\u003e\u003cw:t\u003ehttp://www.mathworks.com/matlabcentral/cody/problems/42461-this-is-a-palindrome-and-so-am-i\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eNote: last line of MATLAB solution is padded with a comment, so you should remove that in your Quine submission\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":1190,"title":"Golomb's self-describing sequence (based on Euler 341)","description":"The Golomb's self-describing sequence {G(n)} is the only nondecreasing sequence of natural numbers such that n appears exactly G(n) times in the sequence. The values of G(n) for the first few n are\r\n\r\n* |n =\u0026nbsp;    1    2    3\t4\t5\t6\t7\t8\t9\t10\t11\t12\t13\t14\t15\t…|\r\n* |G(n) 1    2\t2\t3\t3\t4\t4\t4\t5\t5\t\u0026nbsp;5\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;…|\r\n\r\nWrite a MATLAB script that will give you G(n) when given n.\r\n\r\nEfficiency is key here, since some of the values in the test suite will take a while to calculate.","description_html":"\u003cp\u003eThe Golomb's self-describing sequence {G(n)} is the only nondecreasing sequence of natural numbers such that n appears exactly G(n) times in the sequence. The values of G(n) for the first few n are\u003c/p\u003e\u003cul\u003e\u003cli\u003e\u003ctt\u003en =\u0026nbsp;    1    2    3\t4\t5\t6\t7\t8\t9\t10\t11\t12\t13\t14\t15\t…\u003c/tt\u003e\u003c/li\u003e\u003cli\u003e\u003ctt\u003eG(n) 1    2\t2\t3\t3\t4\t4\t4\t5\t5\t\u0026nbsp;5\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;6\t\u0026nbsp;…\u003c/tt\u003e\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eWrite a MATLAB script that will give you G(n) when given n.\u003c/p\u003e\u003cp\u003eEfficiency is key here, since some of the values in the test suite will take a while to calculate.\u003c/p\u003e","function_template":"function y = euler341(x)\r\n  y = x;\r\nend","test_suite":"%%\r\nassert(isequal(euler341(1),1))\r\n%%\r\nassert(isequal(euler341(10),5))\r\n%%\r\nassert(isequal(euler341(310),42))\r\n%%\r\nassert(isequal(euler341(4242),210))\r\n%%\r\nassert(isequal(euler341(328509),3084))\r\n%%\r\nassert(isequal(euler341(551368),4247))\r\n%%\r\nassert(isequal(euler341(614125),4540))\r\n","published":true,"deleted":false,"likes_count":3,"comments_count":0,"created_by":1615,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":183,"test_suite_updated_at":"2013-10-01T17:43:23.000Z","rescore_all_solutions":false,"group_id":27,"created_at":"2013-01-09T15:55:47.000Z","updated_at":"2026-03-25T04:50:04.000Z","published_at":"2013-01-09T15:55:47.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eThe Golomb's self-describing sequence {G(n)} is the only nondecreasing sequence of natural numbers such that n appears exactly G(n) times in the sequence. The values of G(n) for the first few n are\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:rFonts w:cs=\\\"monospace\\\"/\u003e\u003c/w:rPr\u003e\u003cw:t\u003en = 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 …\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:rFonts w:cs=\\\"monospace\\\"/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eG(n) 1 2 2 3 3 4 4 4 5 5 5 6 6 6 6 …\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite a MATLAB script that will give you G(n) when given n.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eEfficiency is key here, since some of the values in the test suite will take a while to calculate.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":2907,"title":"Collaborative Fun : Nomination","description":"Series of problems have been presented in Cody aiming at collaborative fun. This problem is based on Alfonso's problem #2825 - Pay it Forward. This one encourages more directed collaboration.\r\n\r\nYou can solve this problem only if you are nominated by some other player. Once you are nominated, you can solve it by returning anything. You can nominate a player to solve this problem by returning his player ID.\r\n\r\nThis is not a hacking problem. You should hack only when you are not interested in collaboration.\r\n\r\nExample - I have nominated Alfonso by returning his player ID 1379371. (Since test suite of this problem uses codes from his problem, it is fair to nominate Alfonso)","description_html":"\u003cp\u003eSeries of problems have been presented in Cody aiming at collaborative fun. This problem is based on Alfonso's problem #2825 - Pay it Forward. This one encourages more directed collaboration.\u003c/p\u003e\u003cp\u003eYou can solve this problem only if you are nominated by some other player. Once you are nominated, you can solve it by returning anything. You can nominate a player to solve this problem by returning his player ID.\u003c/p\u003e\u003cp\u003eThis is not a hacking problem. You should hack only when you are not interested in collaboration.\u003c/p\u003e\u003cp\u003eExample - I have nominated Alfonso by returning his player ID 1379371. (Since test suite of this problem uses codes from his problem, it is fair to nominate Alfonso)\u003c/p\u003e","function_template":"function y = nomination(x)\r\n  y = ;\r\nend","test_suite":"lines=textread('nomination.m','%s');\r\nid_own=str2num(regexp(lines{end},'\\d+','match','once'));\r\n\r\nx=uint64(nomination());\r\n\r\nif x == uint64(id_own)\r\n    assignin('caller','score',-1);\r\n    error('Funny! You tried to nominate yourself!')\r\nend\r\n\r\nassignin('caller','score',x);\r\n\r\nproblem=2907;\r\nhtml=urlread(sprintf('http://www.mathworks.com/matlabcentral/cody/problems/%d/solutions?term=size:%d',problem,id_own));\r\nn=numel(regexpi(html,'solution \\d+'));\r\n\r\nif n \u003c 1\r\n    error('Sorry. You are nominated by none.');\r\nend\r\n\r\n\r\n%_______\r\n\r\nurl = sprintf('https://www.mathworks.com/matlabcentral/cody/players/%d',x);\r\nhtml = urlread(url);\r\n\r\nc = regexp(html,'h1.+h1','match');\r\nname = c{1}(4:end-4);\r\n\r\ns = sprintf('____________________\\n\\nYou have nominated %s !!!',name);\r\ndisp(s)","published":true,"deleted":false,"likes_count":4,"comments_count":7,"created_by":17203,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":10,"test_suite_updated_at":"2015-02-01T12:49:00.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2015-01-31T09:55:23.000Z","updated_at":"2025-06-22T16:20:35.000Z","published_at":"2015-01-31T09:55:23.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSeries of problems have been presented in Cody aiming at collaborative fun. This problem is based on Alfonso's problem #2825 - Pay it Forward. This one encourages more directed collaboration.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eYou can solve this problem only if you are nominated by some other player. Once you are nominated, you can solve it by returning anything. You can nominate a player to solve this problem by returning his player ID.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eThis is not a hacking problem. You should hack only when you are not interested in collaboration.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eExample - I have nominated Alfonso by returning his player ID 1379371. (Since test suite of this problem uses codes from his problem, it is fair to nominate Alfonso)\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"},{"id":242,"title":"Make a function that returns its own character count","description":"Write a function that returns a 128 element vector with an accurate inventory of the ASCII characters in its own function file. The test suite uses textscan to verify that your function returns the exact same census.\r\n file = textscan(fid,'%c','CommentStyle','%','Whitespace','')\r\n filetext = file{1};\r\n texthist = histc(filetext,1:128);\r\nNewlines are suppressed by this approach, so you may assume the counts for ASCII 10 and 13 are zero.\r\nSpecial Note: The characters associated with ASCII values 33-41 are not allowed in your function. For clarity, these are\r\n 33 !\r\n 34 \"\r\n 35 #\r\n 36 $\r\n 37 %\r\n 38 \u0026\r\n 39 '\r\n 40 (\r\n 41 )","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.4333px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: rgb(0, 0, 0); white-space: normal; \"\u003e\u003cdiv style=\"block-size: 368.2px; display: block; min-width: 0px; padding-block-start: 0px; padding-top: 0px; perspective-origin: 407px 184.1px; transform-origin: 407px 184.1px; vertical-align: baseline; \"\u003e\u003cdiv style=\"block-size: 42px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 21px; text-align: left; transform-origin: 384px 21px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 375.5px 8px; transform-origin: 375.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eWrite a function that returns a 128 element vector with an accurate inventory of the ASCII characters in its own function file. The test suite uses textscan to verify that your function returns the exact same census.\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgb(247, 247, 247); block-size: 61.3px; border-bottom-left-radius: 4px; border-bottom-right-radius: 4px; border-end-end-radius: 4px; border-end-start-radius: 4px; border-start-end-radius: 4px; border-start-start-radius: 4px; border-top-left-radius: 4px; border-top-right-radius: 4px; margin-block-end: 10px; margin-block-start: 10px; margin-bottom: 10px; margin-inline-end: 3px; margin-inline-start: 3px; margin-left: 3px; margin-right: 3px; margin-top: 10px; perspective-origin: 404px 30.65px; transform-origin: 404px 30.65px; margin-left: 3px; margin-top: 10px; margin-bottom: 10px; margin-right: 3px; \"\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 244px 8.5px; tab-size: 4; transform-origin: 244px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 84px 8.5px; transform-origin: 84px 8.5px; \"\u003e file = textscan(fid,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 16px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 16px 8.5px; \"\u003e'%c'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 56px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 56px 8.5px; \"\u003e'CommentStyle'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 12px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 12px 8.5px; \"\u003e'%'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 48px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 48px 8.5px; \"\u003e'Whitespace'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e,\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 8px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 8px 8.5px; \"\u003e''\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e)\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 80px 8.5px; tab-size: 4; transform-origin: 80px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e filetext = file{1};\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 136px 8.5px; tab-size: 4; transform-origin: 136px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e texthist = histc(filetext,1:128);\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 10px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 10px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 10px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 328.5px 8px; transform-origin: 328.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eNewlines are suppressed by this approach, so you may assume the counts for ASCII 10 and 13 are zero.\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 46px 8px; transform-origin: 46px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"font-weight: 700; \"\u003eSpecial Note:\u003c/span\u003e\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 331.5px 8px; transform-origin: 331.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e The characters associated with ASCII values 33-41 are not allowed in your function. For clarity, these are\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgb(247, 247, 247); block-size: 183.9px; border-bottom-left-radius: 4px; border-bottom-right-radius: 4px; border-end-end-radius: 4px; border-end-start-radius: 4px; border-start-end-radius: 4px; border-start-start-radius: 4px; border-top-left-radius: 4px; border-top-right-radius: 4px; margin-block-end: 10px; margin-block-start: 10px; margin-bottom: 10px; margin-inline-end: 3px; margin-inline-start: 3px; margin-left: 3px; margin-right: 3px; margin-top: 10px; perspective-origin: 404px 91.95px; transform-origin: 404px 91.95px; margin-left: 3px; margin-top: 10px; margin-bottom: 10px; margin-right: 3px; \"\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 33 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(178, 140, 0); border-block-start-color: rgb(178, 140, 0); border-bottom-color: rgb(178, 140, 0); border-inline-end-color: rgb(178, 140, 0); border-inline-start-color: rgb(178, 140, 0); border-left-color: rgb(178, 140, 0); border-right-color: rgb(178, 140, 0); border-top-color: rgb(178, 140, 0); caret-color: rgb(178, 140, 0); color: rgb(178, 140, 0); column-rule-color: rgb(178, 140, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(178, 140, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(178, 140, 0); text-emphasis-color: rgb(178, 140, 0); transform-origin: 4px 8.5px; \"\u003e!\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 34 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(196, 0, 0); border-block-start-color: rgb(196, 0, 0); border-bottom-color: rgb(196, 0, 0); border-inline-end-color: rgb(196, 0, 0); border-inline-start-color: rgb(196, 0, 0); border-left-color: rgb(196, 0, 0); border-right-color: rgb(196, 0, 0); border-top-color: rgb(196, 0, 0); caret-color: rgb(196, 0, 0); color: rgb(196, 0, 0); column-rule-color: rgb(196, 0, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(196, 0, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(196, 0, 0); text-emphasis-color: rgb(196, 0, 0); transform-origin: 4px 8.5px; \"\u003e\"\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 35 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(255, 0, 0); border-block-start-color: rgb(255, 0, 0); border-bottom-color: rgb(255, 0, 0); border-inline-end-color: rgb(255, 0, 0); border-inline-start-color: rgb(255, 0, 0); border-left-color: rgb(255, 0, 0); border-right-color: rgb(255, 0, 0); border-top-color: rgb(255, 0, 0); caret-color: rgb(255, 0, 0); color: rgb(255, 0, 0); column-rule-color: rgb(255, 0, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(255, 0, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(255, 0, 0); text-emphasis-color: rgb(255, 0, 0); transform-origin: 4px 8.5px; \"\u003e#\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 36 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(255, 0, 0); border-block-start-color: rgb(255, 0, 0); border-bottom-color: rgb(255, 0, 0); border-inline-end-color: rgb(255, 0, 0); border-inline-start-color: rgb(255, 0, 0); border-left-color: rgb(255, 0, 0); border-right-color: rgb(255, 0, 0); border-top-color: rgb(255, 0, 0); caret-color: rgb(255, 0, 0); color: rgb(255, 0, 0); column-rule-color: rgb(255, 0, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(255, 0, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(255, 0, 0); text-emphasis-color: rgb(255, 0, 0); transform-origin: 4px 8.5px; \"\u003e$\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 37 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(2, 128, 9); border-block-start-color: rgb(2, 128, 9); border-bottom-color: rgb(2, 128, 9); border-inline-end-color: rgb(2, 128, 9); border-inline-start-color: rgb(2, 128, 9); border-left-color: rgb(2, 128, 9); border-right-color: rgb(2, 128, 9); border-top-color: rgb(2, 128, 9); caret-color: rgb(2, 128, 9); color: rgb(2, 128, 9); column-rule-color: rgb(2, 128, 9); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(2, 128, 9); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(2, 128, 9); text-emphasis-color: rgb(2, 128, 9); transform-origin: 4px 8.5px; \"\u003e%\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e 38 \u0026amp;\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 16px 8.5px; transform-origin: 16px 8.5px; \"\u003e 39 \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(196, 0, 0); border-block-start-color: rgb(196, 0, 0); border-bottom-color: rgb(196, 0, 0); border-inline-end-color: rgb(196, 0, 0); border-inline-start-color: rgb(196, 0, 0); border-left-color: rgb(196, 0, 0); border-right-color: rgb(196, 0, 0); border-top-color: rgb(196, 0, 0); caret-color: rgb(196, 0, 0); color: rgb(196, 0, 0); column-rule-color: rgb(196, 0, 0); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(196, 0, 0); perspective-origin: 4px 8.5px; text-decoration: none; text-decoration-color: rgb(196, 0, 0); text-emphasis-color: rgb(196, 0, 0); transform-origin: 4px 8.5px; \"\u003e'\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e 40 (\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 20px 8.5px; tab-size: 4; transform-origin: 20px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; \"\u003e 41 )\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function x = omphaloskeptic\r\n  x = 0;\r\nend","test_suite":"%%\r\nfname = 'omphaloskeptic.m';\r\nfid = fopen(fname);\r\nfile = textscan(fid,'%c', ...\r\n  'CommentStyle','%', ...\r\n  'Whitespace','');\r\nfclose(fid);\r\n\r\nha = histc(file{1},1:128);\r\nhp = omphaloskeptic;\r\n\r\nassert(~any(ismember(33:41,find(ha))),'Used an illegal character');\r\nassert(isequal(ha,hp),'Actual characters did not match prediction');","published":true,"deleted":false,"likes_count":4,"comments_count":1,"created_by":7,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":34,"test_suite_updated_at":"2021-09-07T15:14:16.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2012-02-02T22:19:52.000Z","updated_at":"2026-03-21T04:10:51.000Z","published_at":"2012-02-03T15:28:39.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite a function that returns a 128 element vector with an accurate inventory of the ASCII characters in its own function file. The test suite uses textscan to verify that your function returns the exact same census.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ file = textscan(fid,'%c','CommentStyle','%','Whitespace','')\\n filetext = file{1};\\n texthist = histc(filetext,1:128);]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eNewlines are suppressed by this approach, so you may assume the counts for ASCII 10 and 13 are zero.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eSpecial Note:\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e The characters associated with ASCII values 33-41 are not allowed in your function. For clarity, these are\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ 33 !\\n 34 \\\"\\n 35 #\\n 36 $\\n 37 %\\n 38 \u0026\\n 39 '\\n 40 (\\n 41 )]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":43676,"title":"Count the Digits in the Box","description":"In this problem you must provide an accurate census of all the digits inside a given box. The problem is complicated by the fact that your census report also appears inside the box, thereby influencing the result. Here is the simplest form of the problem.\r\n\r\n ----------------------------------------------\r\n |  The number of 0's inside the box is: ___  |\r\n |  The number of 1's inside the box is: ___  |\r\n |  The number of 2's inside the box is: ___  |\r\n |  The number of 3's inside the box is: ___  |\r\n |  The number of 4's inside the box is: ___  |\r\n |  The number of 5's inside the box is: ___  |\r\n |  The number of 6's inside the box is: ___  |\r\n |  The number of 7's inside the box is: ___  |\r\n |  The number of 8's inside the box is: ___  |\r\n |  The number of 9's inside the box is: ___  |\r\n ----------------------------------------------\r\n\r\nSuppose you start to fill it in like this: there's only one 2, so you put a 1 next to the 2. But there are now two 1's, so you put a 2 next to the 1. But now there are three 2's... and so on. This problem eventually converges and can be answered as follows.\r\n\r\n --------------------------------------------\r\n | The number of 0's inside the box is:   1 |\r\n | The number of 1's inside the box is:   7 |\r\n | The number of 2's inside the box is:   3 |\r\n | The number of 3's inside the box is:   2 |\r\n | The number of 4's inside the box is:   1 |\r\n | The number of 5's inside the box is:   1 |\r\n | The number of 6's inside the box is:   1 |\r\n | The number of 7's inside the box is:   2 |\r\n | The number of 8's inside the box is:   1 |\r\n | The number of 9's inside the box is:   1 |\r\n --------------------------------------------\r\n\r\nCount the numbers and you'll see the sums all work out. We will complicate this problem by adding some extra numbers to the top of the box. \r\n\r\n*Example*\r\n\r\nIf\r\n\r\n extras = 22222\r\n\r\nthen we can see by inspection that one solution is\r\n\r\n census = [1 7 7 2 1 1 1 3 1 1]\r\n\r\nas shown below\r\n\r\n --------------------------------------------\r\n | Here are some extra numbers:       22222 |\r\n | The number of 0's inside the box is:   1 |\r\n | The number of 1's inside the box is:   7 |\r\n | The number of 2's inside the box is:   7 |\r\n | The number of 3's inside the box is:   2 |\r\n | The number of 4's inside the box is:   1 |\r\n | The number of 5's inside the box is:   1 |\r\n | The number of 6's inside the box is:   1 |\r\n | The number of 7's inside the box is:   3 |\r\n | The number of 8's inside the box is:   1 |\r\n | The number of 9's inside the box is:   1 |\r\n --------------------------------------------\r\n\r\nIn general, your answer might not be unique. We'll just test whether you meet the criteria.","description_html":"\u003cp\u003eIn this problem you must provide an accurate census of all the digits inside a given box. The problem is complicated by the fact that your census report also appears inside the box, thereby influencing the result. Here is the simplest form of the problem.\u003c/p\u003e\u003cpre\u003e ----------------------------------------------\r\n |  The number of 0's inside the box is: ___  |\r\n |  The number of 1's inside the box is: ___  |\r\n |  The number of 2's inside the box is: ___  |\r\n |  The number of 3's inside the box is: ___  |\r\n |  The number of 4's inside the box is: ___  |\r\n |  The number of 5's inside the box is: ___  |\r\n |  The number of 6's inside the box is: ___  |\r\n |  The number of 7's inside the box is: ___  |\r\n |  The number of 8's inside the box is: ___  |\r\n |  The number of 9's inside the box is: ___  |\r\n ----------------------------------------------\u003c/pre\u003e\u003cp\u003eSuppose you start to fill it in like this: there's only one 2, so you put a 1 next to the 2. But there are now two 1's, so you put a 2 next to the 1. But now there are three 2's... and so on. This problem eventually converges and can be answered as follows.\u003c/p\u003e\u003cpre\u003e --------------------------------------------\r\n | The number of 0's inside the box is:   1 |\r\n | The number of 1's inside the box is:   7 |\r\n | The number of 2's inside the box is:   3 |\r\n | The number of 3's inside the box is:   2 |\r\n | The number of 4's inside the box is:   1 |\r\n | The number of 5's inside the box is:   1 |\r\n | The number of 6's inside the box is:   1 |\r\n | The number of 7's inside the box is:   2 |\r\n | The number of 8's inside the box is:   1 |\r\n | The number of 9's inside the box is:   1 |\r\n --------------------------------------------\u003c/pre\u003e\u003cp\u003eCount the numbers and you'll see the sums all work out. We will complicate this problem by adding some extra numbers to the top of the box.\u003c/p\u003e\u003cp\u003e\u003cb\u003eExample\u003c/b\u003e\u003c/p\u003e\u003cp\u003eIf\u003c/p\u003e\u003cpre\u003e extras = 22222\u003c/pre\u003e\u003cp\u003ethen we can see by inspection that one solution is\u003c/p\u003e\u003cpre\u003e census = [1 7 7 2 1 1 1 3 1 1]\u003c/pre\u003e\u003cp\u003eas shown below\u003c/p\u003e\u003cpre\u003e --------------------------------------------\r\n | Here are some extra numbers:       22222 |\r\n | The number of 0's inside the box is:   1 |\r\n | The number of 1's inside the box is:   7 |\r\n | The number of 2's inside the box is:   7 |\r\n | The number of 3's inside the box is:   2 |\r\n | The number of 4's inside the box is:   1 |\r\n | The number of 5's inside the box is:   1 |\r\n | The number of 6's inside the box is:   1 |\r\n | The number of 7's inside the box is:   3 |\r\n | The number of 8's inside the box is:   1 |\r\n | The number of 9's inside the box is:   1 |\r\n --------------------------------------------\u003c/pre\u003e\u003cp\u003eIn general, your answer might not be unique. We'll just test whether you meet the criteria.\u003c/p\u003e","function_template":"function census = getDigitCensus(extras)\r\n  census = [0 0 0 0 0 0 0 0 0 0];\r\nend","test_suite":"%%\r\nextras = 22222;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 6380059;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 99999432;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 347879;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 83870955;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))\r\n\r\n%%\r\nextras = 1111111111;\r\ncensusIn = getDigitCensus(extras)\r\nstr = string(censusIn);\r\ncensusOut = histc(char([str{:}]+string(extras))-48,0:9)+1;\r\nassert(isequal(censusIn,censusOut))","published":true,"deleted":false,"likes_count":3,"comments_count":4,"created_by":7,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":6,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2016-11-21T20:00:30.000Z","updated_at":"2016-12-14T15:19:55.000Z","published_at":"2016-12-13T23:01:52.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eIn this problem you must provide an accurate census of all the digits inside a given box. The problem is complicated by the fact that your census report also appears inside the box, thereby influencing the result. Here is the simplest form of the problem.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ ----------------------------------------------\\n |  The number of 0's inside the box is: ___  |\\n |  The number of 1's inside the box is: ___  |\\n |  The number of 2's inside the box is: ___  |\\n |  The number of 3's inside the box is: ___  |\\n |  The number of 4's inside the box is: ___  |\\n |  The number of 5's inside the box is: ___  |\\n |  The number of 6's inside the box is: ___  |\\n |  The number of 7's inside the box is: ___  |\\n |  The number of 8's inside the box is: ___  |\\n |  The number of 9's inside the box is: ___  |\\n ----------------------------------------------]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSuppose you start to fill it in like this: there's only one 2, so you put a 1 next to the 2. But there are now two 1's, so you put a 2 next to the 1. But now there are three 2's... and so on. This problem eventually converges and can be answered as follows.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ --------------------------------------------\\n | The number of 0's inside the box is:   1 |\\n | The number of 1's inside the box is:   7 |\\n | The number of 2's inside the box is:   3 |\\n | The number of 3's inside the box is:   2 |\\n | The number of 4's inside the box is:   1 |\\n | The number of 5's inside the box is:   1 |\\n | The number of 6's inside the box is:   1 |\\n | The number of 7's inside the box is:   2 |\\n | The number of 8's inside the box is:   1 |\\n | The number of 9's inside the box is:   1 |\\n --------------------------------------------]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eCount the numbers and you'll see the sums all work out. We will complicate this problem by adding some extra numbers to the top of the box.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:rPr\u003e\u003cw:b/\u003e\u003c/w:rPr\u003e\u003cw:t\u003eExample\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eIf\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ extras = 22222]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003ethen we can see by inspection that one solution is\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ census = [1 7 7 2 1 1 1 3 1 1]]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eas shown below\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[ --------------------------------------------\\n | Here are some extra numbers:       22222 |\\n | The number of 0's inside the box is:   1 |\\n | The number of 1's inside the box is:   7 |\\n | The number of 2's inside the box is:   7 |\\n | The number of 3's inside the box is:   2 |\\n | The number of 4's inside the box is:   1 |\\n | The number of 5's inside the box is:   1 |\\n | The number of 6's inside the box is:   1 |\\n | The number of 7's inside the box is:   3 |\\n | The number of 8's inside the box is:   1 |\\n | The number of 9's inside the box is:   1 |\\n --------------------------------------------]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eIn general, your answer might not be unique. We'll just test whether you meet the criteria.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"}],"term":"tag:\"self-referential\"","current_player_id":null,"fields":[{"name":"page","type":"integer","callback":null,"default":1,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":null,"static":null,"prepend":true},{"name":"per_page","type":"integer","callback":null,"default":50,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":null,"static":null,"prepend":true},{"name":"sort","type":"string","callback":null,"default":null,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":null,"static":null,"prepend":true},{"name":"body","type":"text","callback":null,"default":"*:*","directive":null,"facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":false},{"name":"group","type":"string","callback":null,"default":null,"directive":"group","facet":true,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"difficulty_rating_bin","type":"string","callback":null,"default":null,"directive":"difficulty_rating_bin","facet":true,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"id","type":"integer","callback":null,"default":null,"directive":"id","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"tag","type":"string","callback":null,"default":null,"directive":"tag","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"product","type":"string","callback":null,"default":null,"directive":"product","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"created_at","type":"timeframe","callback":{},"default":null,"directive":"created_at","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"profile_id","type":"integer","callback":null,"default":null,"directive":"author_id","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"created_by","type":"string","callback":null,"default":null,"directive":"author","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"player_id","type":"integer","callback":null,"default":null,"directive":"solver_id","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"player","type":"string","callback":null,"default":null,"directive":"solver","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"solvers_count","type":"integer","callback":null,"default":null,"directive":"solvers_count","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"comments_count","type":"integer","callback":null,"default":null,"directive":"comments_count","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"likes_count","type":"integer","callback":null,"default":null,"directive":"likes_count","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"leader_id","type":"integer","callback":null,"default":null,"directive":"leader_id","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"leading_solution","type":"integer","callback":null,"default":null,"directive":"leading_solution","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true}],"filters":[{"name":"asset_type","type":"string","callback":null,"default":null,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":null,"static":"\"cody:problem\"","prepend":true},{"name":"profile_id","type":"integer","callback":{},"default":null,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":"author_id","static":null,"prepend":true}],"query":{"params":{"per_page":50,"term":"tag:\"self-referential\"","current_player":null,"sort":"map(difficulty_value,0,0,999) asc"},"parser":"MathWorks::Search::Solr::QueryParser","directives":{"term":{"directives":{"tag":[["tag:\"self-referential\"","","\"","self-referential","\""]]}}},"facets":{"#\u003cMathWorks::Search::Field:0x00007fbf38804388\u003e":null,"#\u003cMathWorks::Search::Field:0x00007fbf388042e8\u003e":null},"filters":{"#\u003cMathWorks::Search::Field:0x00007fbf38803708\u003e":"\"cody:problem\""},"fields":{"#\u003cMathWorks::Search::Field:0x00007fbf388047e8\u003e":1,"#\u003cMathWorks::Search::Field:0x00007fbf38804608\u003e":50,"#\u003cMathWorks::Search::Field:0x00007fbf38804568\u003e":"map(difficulty_value,0,0,999) asc","#\u003cMathWorks::Search::Field:0x00007fbf38804428\u003e":"tag:\"self-referential\""},"user_query":{"#\u003cMathWorks::Search::Field:0x00007fbf38804428\u003e":"tag:\"self-referential\""},"queried_facets":{}},"query_backend":{"connection":{"configuration":{"index_url":"http://index-op-v2/solr/","query_url":"http://search-op-v2/solr/","direct_access_index_urls":["http://index-op-v2/solr/"],"direct_access_query_urls":["http://search-op-v2/solr/"],"timeout":10,"vhost":"search","exchange":"search.topic","heartbeat":30,"pre_index_mode":false,"host":"rabbitmq-eks","port":5672,"username":"cody-search","password":"78X075ddcV44","virtual_host":"search","indexer":"amqp","http_logging":"true","core":"cody"},"query_connection":{"uri":"http://search-op-v2/solr/cody/","proxy":null,"connection":{"parallel_manager":null,"headers":{"User-Agent":"Faraday v1.0.1"},"params":{},"options":{"params_encoder":"Faraday::FlatParamsEncoder","proxy":null,"bind":null,"timeout":null,"open_timeout":null,"read_timeout":null,"write_timeout":null,"boundary":null,"oauth":null,"context":null,"on_data":null},"ssl":{"verify":true,"ca_file":null,"ca_path":null,"verify_mode":null,"cert_store":null,"client_cert":null,"client_key":null,"certificate":null,"private_key":null,"verify_depth":null,"version":null,"min_version":null,"max_version":null},"default_parallel_manager":null,"builder":{"adapter":{"name":"Faraday::Adapter::NetHttp","args":[],"block":null},"handlers":[{"name":"Faraday::Response::RaiseError","args":[],"block":null}],"app":{"app":{"ssl_cert_store":{"verify_callback":null,"error":null,"error_string":null,"chain":null,"time":null},"app":{},"connection_options":{},"config_block":null}}},"url_prefix":"http://search-op-v2/solr/cody/","manual_proxy":false,"proxy":null},"update_format":"RSolr::JSON::Generator","update_path":"update","options":{"url":"http://search-op-v2/solr/cody"}}},"query":{"params":{"per_page":50,"term":"tag:\"self-referential\"","current_player":null,"sort":"map(difficulty_value,0,0,999) asc"},"parser":"MathWorks::Search::Solr::QueryParser","directives":{"term":{"directives":{"tag":[["tag:\"self-referential\"","","\"","self-referential","\""]]}}},"facets":{"#\u003cMathWorks::Search::Field:0x00007fbf38804388\u003e":null,"#\u003cMathWorks::Search::Field:0x00007fbf388042e8\u003e":null},"filters":{"#\u003cMathWorks::Search::Field:0x00007fbf38803708\u003e":"\"cody:problem\""},"fields":{"#\u003cMathWorks::Search::Field:0x00007fbf388047e8\u003e":1,"#\u003cMathWorks::Search::Field:0x00007fbf38804608\u003e":50,"#\u003cMathWorks::Search::Field:0x00007fbf38804568\u003e":"map(difficulty_value,0,0,999) asc","#\u003cMathWorks::Search::Field:0x00007fbf38804428\u003e":"tag:\"self-referential\""},"user_query":{"#\u003cMathWorks::Search::Field:0x00007fbf38804428\u003e":"tag:\"self-referential\""},"queried_facets":{}},"options":{"fields":["id","difficulty_rating"]},"join":" "},"results":[{"id":2313,"difficulty_rating":"easy"},{"id":2312,"difficulty_rating":"easy"},{"id":1969,"difficulty_rating":"easy-medium"},{"id":42461,"difficulty_rating":"easy-medium"},{"id":42491,"difficulty_rating":"medium"},{"id":1190,"difficulty_rating":"medium"},{"id":2907,"difficulty_rating":"medium"},{"id":242,"difficulty_rating":"medium-hard"},{"id":43676,"difficulty_rating":"unrated"}]}}