#include <iostream> using namespace std; int f[50]={0,1,1}; int main(){ int n,s=0; cin>>n; for(int i=3;i<=40;i++) f[i]=f[i-1]+f[i-2]; for(int i=1;i<=n;i++) s+=f[i]; cout<<s; }…
Description The number 151 is a prime palindrome because it is both a prime number and a palindrome (it is the same number when read forward as backward). Write a program that finds all prime palindromes in the range of two supplied numbers a and b (…