Cody

Problem 44861. Ratio between sums of prime and non-prime numbers

Solution 2682230

Submitted on 12 Jul 2020
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   Fail
x = 12; y_correct = 28/38; assert(isequal(your_fcn_name(x),y_correct))

Error in solution: Line: 2 Column: 20 Invalid expression. When calling a function or indexing a variable, use parentheses. Otherwise, check for mismatched delimiters.

2   Fail
x = 7; y_correct = 17/11; assert(isequal(your_fcn_name(x),y_correct))

Error in solution: Line: 2 Column: 20 Invalid expression. When calling a function or indexing a variable, use parentheses. Otherwise, check for mismatched delimiters.

3   Fail
x = 20; y_correct = 77/113; assert(isequal(your_fcn_name(x),y_correct))

Error in solution: Line: 2 Column: 20 Invalid expression. When calling a function or indexing a variable, use parentheses. Otherwise, check for mismatched delimiters.

Suggested Problems

More from this Author10

Community Treasure Hunt

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

Start Hunting!