0% found this document useful (0 votes)
15 views

Python Project

The document describes a Python program to find the nth prime palindrome number based on a user-entered value of n. The program first checks if the number is prime, then checks if it is a palindrome. It prints results stating whether the number is or isn't a prime palindrome. The document includes sections on the project title, code design and source code, and a conclusion stating the goal is to understand the Python program to find nth prime palindromes.

Uploaded by

Anshul Choudhary
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views

Python Project

The document describes a Python program to find the nth prime palindrome number based on a user-entered value of n. The program first checks if the number is prime, then checks if it is a palindrome. It prints results stating whether the number is or isn't a prime palindrome. The document includes sections on the project title, code design and source code, and a conclusion stating the goal is to understand the Python program to find nth prime palindromes.

Uploaded by

Anshul Choudhary
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

A Python Report

Project Title:-
Your task is to write a program to find the
nth prime palindrome number, n is the
input user will give
prime and a palindrome..

BACHELOR OF TECHNOLOGY
Computer science and Engineering

Submitted to
Dr. Makul Mahajan
LOVELY PROFESSIONAL UNIVERSITY
PHAGWARA, PUNJAB

SUBMITTED BY :- Ishan Jaiswal Reg.No:-12210079 Roll No:-60


ACKNOWLEDGEMENT

No doubt this project is only possible because of my


mentor and my Prof. Dr. Makul Mahajan sir and
We would like to thanks him from depth of our
heartfor giving us knowledge of Python and for also
giving me so many advices and various more inputs
in this project. And also We want to say thanks to
my all friends and family who gave me so many
wonderful feedbacks in this project.
DESIGN AND SOURCE CODE:-

This is the code’s screenshot and the code of this is at the next page,
SOURCE CODE:-
print('WELCOME! What is your name?')
myName = input()
print('Hello ' + myName + ' Enter random number')
n=int(input("Enter any number: "))
#prime check
f=0
for i in range(2,n):
if n%i==0:
print(i)
f=1
break
if f==1:
print(n,"is not a prime")
else:
print(n,"is prime")
#palindrom number
x=n
sum=0
while x>0:
r=x%10
sum=sum*10+r
x=x//10
if sum==n:
print(n,"is a prime palindrom")
else:
print(n,"is not a prime palindrom")
Result page:-
Conclusion
We hope and we wish that this document will
help you to understand about our minimalist
but attractive project as I had tried something
different from usual. We had used Python
for logical.

You might also like