Cody

Problem 43611. microseconds passed today

Solution 2909326

Submitted on 4 Sep 2020
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
x = '24-Oct-2016 20:26:28'; y_correct = '73588000000'; assert(isequal(microsecondsPassedToday(x),y_correct))

Error: File: microsecondsPassedToday.m Line: 3 Column: 34 The end operator must be used within an array index expression. Error in Test1 (line 3) assert(isequal(microsecondsPassedToday(x),y_correct))

2   Fail
x = '24-Oct-2016 20:29:48'; y_correct = '73788000000'; assert(isequal(microsecondsPassedToday(x),y_correct))

Error: File: microsecondsPassedToday.m Line: 3 Column: 34 The end operator must be used within an array index expression. Error in Test2 (line 3) assert(isequal(microsecondsPassedToday(x),y_correct))

3   Fail
x = '14-Feb-2002 08:19:04'; y_correct = '29944000000'; assert(isequal(microsecondsPassedToday(x),y_correct))

Error: File: microsecondsPassedToday.m Line: 3 Column: 34 The end operator must be used within an array index expression. Error in Test3 (line 3) assert(isequal(microsecondsPassedToday(x),y_correct))

4   Fail
x = '07-Apr-1902 10:00:00'; y_correct = '36000000000'; assert(isequal(microsecondsPassedToday(x),y_correct))

Error: File: microsecondsPassedToday.m Line: 3 Column: 34 The end operator must be used within an array index expression. Error in Test4 (line 3) assert(isequal(microsecondsPassedToday(x),y_correct))

5   Fail
x = '11-Nov-1911 11:11:11'; y_correct = '40271000000'; assert(isequal(microsecondsPassedToday(x),y_correct))

Error: File: microsecondsPassedToday.m Line: 3 Column: 34 The end operator must be used within an array index expression. Error in Test5 (line 3) assert(isequal(microsecondsPassedToday(x),y_correct))

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!