Skip to content

Noxtal/palindromicprimes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

palindromicprimes

This is a Python module to find palindromic primes up to 99999199999.

Usage

Install

$ pip install palindromicprimes

How to use

Find the nth palindromic prime:

import palindromicprimes as palprimes

print(palprimes.nthPalindromicPrime(10))

Find the lowest nearest palindromic prime to a number:

import palindromicprimes as palprimes

print(palprimes.lowestNearestPalindromicPrime(50000))

Note: this function returns both the index of this prime in the list and the prime itself.

Created for the NahamCon CTF 2020 (see more here). Based on the A002385 number set.

For more things I did, see my website.

About

Python library to search through palindromic primes. Based on the A002385 number set. Created for the NahamCon CTF 2020.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages