Problem 1160. Gene Sequence Contest: Retro

Solution 1668967

Submitted on 8 Nov 2018
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

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

Test Suite

Test Status Code Input and Output
1   Pass

2   Fail
tic urlwrite('','testsuite_GeneSeq_contest.mat') toc

Error using urlreadwrite (line 98) Error downloading URL. Your network connection may be down or your proxy settings improperly configured. Error in urlwrite (line 52) [f,status] = urlreadwrite(mfilename,catchErrors,url,filename,varargin{:}); Error in Test2 (line 2) urlwrite('','testsuite_GeneSeq_contest.mat')

3   Fail
load testsuite_GeneSeq_contest cases=size(testsuite,2); Result=zeros(cases,3); for i=1:27 % Practice runs segments=testsuite{i}; solution = geneseq(segments); end % i cases for i=1:29 %1:29 %cases segments=testsuite{i}; OriginalGene=one_answer{i}; t0 = cputime; solution = geneseq(segments); % 99.998065 51667.47 0.452 time_elapsed = cputime-t0; % Check = checksequence(segments,solution); Check=1; for ichk = 1:size(segments,1) if isempty(findstr(segments(ichk,:),solution)) Check=0; break end end if Check == 1 Result(i,1) = length(solution); Result(i,2) = time_elapsed; Result(i,3) = length(OriginalGene); else Result(i,:) = Inf; end end % i cases fprintf('Net Time=%10.6f\n',sum(Result(:,2))) fprintf('Result= %10.6f\n',100*sum(Result(:,1))/sum(Result(:,3))) v=1000*(sum(Result(:,1)./Result(:,3))/size(Result,1)-1)+ sum(Result(:,2))*10; fprintf('Final Score %.2f\n',v) fprintf('L %5i Time %7.3f L_orig %5i\n',Result') assert(max(Result(:,1))< Inf) feval( @assignin,'caller','score',floor(min( 100,v )) );

Error using load Unable to read file 'testsuite_GeneSeq_contest'. No such file or directory. Error in Test3 (line 1) load testsuite_GeneSeq_contest