Cody

Problem 44284. Given a number N, find the smallest prime P>N

Created by AMITAVA BISWAS in Community

Given a number N, find the smallest prime P greater than N. For example: If N=10 then P=11. If N=13 then P=17.

Solution Stats

85.0% Correct | 15.0% Incorrect
Last solution submitted on Feb 15, 2018

Problem Comments

Recent Solvers20

Tags

Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

MATLAB Academy

New to MATLAB?

Learn MATLAB today!