Hi fellas..this is my first post here..I am new to this 'hardcore programming' and all..I came across a problem for which I killed some time..with no fruits..It might be simple,trivial or even 'famous' for you guys..Any assistance is appreciated much.So here it goes..
Given an integer,the problem is to find the prime number combination whose product form the number since any integer can be given as a product of one or more primary numbers..
For eg..for 36,the solution would be 2,2,3,3.
Another thing..a pseudo code or algorithmic description is sufficient..thanks again..
Rexzie 0 Newbie Poster
Recommended Answers
Jump to Post1) Create an array of prime numbers less than or equal to the given number.
2) If the given number is prime, you're done.
3) If not find the smallest prime number that is a factor of the given number and then find the other factor associated with that prime …
All 3 Replies
NathanOliver 429 Veteran Poster Featured Poster
Lerner 582 Nearly a Posting Maven
Rexzie 0 Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.