Algorithm to find out whether an input is a prime number or not

Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
1 reply · 2K views
hadi amiri 4
Messages
98
Reaction score
1

Homework Statement



1- write an algorithm to find out whether an input is a prime number
or not.
2-write aa program to compute square root by Newton method
3-write an algorithm to show an input is perfect or not.
4-

Homework Equations





The Attempt at a Solution

 
Physics news on Phys.org


hadi amiri 4 said:

Homework Statement



1- write an algorithm to find out whether an input is a prime number
or not.
2-write aa program to compute square root by Newton method
3-write an algorithm to show an input is perfect or not.
4-

Homework Equations





The Attempt at a Solution

Before getting any help on this forum, you need to show what you have tried to do.