This solution is outdated. To rescore this solution, sign in.
Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
x = 'C:\foo\bar\baz\qux';
assert(isequal(shorten(x),'C:\..\qux'))
ans =
[]
|
2 | Pass |
x = 'this\is\just\a\test';
assert(isequal(shorten(x),'this\..\test'))
ans =
[]
|
3 | Pass |
x = 'testing\testing\123.mat';
assert(isequal(shorten(x),'testing\..\123.mat'))
ans =
[]
|
Return the 3n+1 sequence for n
6167 Solvers
272 Solvers
202 Solvers
253 Solvers
Convert a vector into a number
503 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!