Capgemini interview question

Prime number,fibonacci program logic about my project