Cody

Solution 1804470

Submitted on 3 May 2019
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Fail
filetext = fileread('dtrmnt_3x3.m'); assert(isempty(strfind(filetext, 'det')),'det() forbidden')

det() forbidden

2   Pass
x = [3 0 2; 2 1 -2; 0 1 1]; y_correct = 13; assert(sum(sum(abs(dtrmnt_3x3(x)-y_correct)))<1e-3)

ans = 13.0000

3   Pass
x = [1 40 2; 7 -9 10; 1 0 1]; y_correct = 129; assert(sum(sum(abs(dtrmnt_3x3(x)-y_correct)))<1e-3)

ans = 129.0000