Posts Topics Forums Images
Search videos from message boards Videos Search messages from microblogs Microblogs Search messages from imdb.com Imdb Search messages from yuku.com Yuku Search messages from lefora.com (free forums) Lefora
My account: Login | Sign Up
Loading... 

Thread: Help with factorize function

Started 1 month, 4 weeks ago by gretty
Hello HELP Ok I have an assignment due in 5 days. I have done everything except for one function. This function finds the smallests factors of a positive int & it multiplicities, Have I lost you yet, dont worry because I've been lost for a week now with this function :P Heres the funny part... we are given the algorithm!! But I cannot for the life of me understand it. I have ...
Site: CodeGuru Forums - A Developer.com Community for C++, C#, VB, Java and .NET Solutions  CodeGuru Forums - A Developer.com Community for C++, C#, VB, Java and .NET Solutions - site profile
Forum: C++ (Non Visual C++ Issues)  C++ (Non Visual C++ Issues) - forum profile
Total authors: 2 authors
Total thread posts: 2 posts
Thread activity: no new posts during last week
Domain info for: codeguru.com

Other posts in this thread:

VladimirF replied 1 month, 4 weeks ago
It would help a LOT if you would insert comments (with the steps from that algorithm) into your code, so that you can see what is done and where. Something like that: Code: // positive integer I is given void factor(int I) { // P = 1 int P = 1; int mult; // while (I > 1) while (I > 1) { // P = P + 1 P = P+1; // what is this ...

 

Top contributing authors

Name
Posts
gretty
1
user's latest post:
Help with factorize function
Published (2009-11-05 19:20:00)
Hello HELP Ok I have an assignment due in 5 days. I have done everything except for one function. This function finds the smallests factors of a positive int & it multiplicities, Have I lost you yet, dont worry because I've been lost for a week now with this function :P Heres the funny part... we are given the algorithm!! But I cannot for the life of me understand it. I have rewritten, written, pulled my hair out for days trying...
VladimirF
1
user's latest post:
Help with factorize function
Published (2009-11-05 19:50:00)
It would help a LOT if you would insert comments (with the steps from that algorithm) into your code, so that you can see what is done and where. Something like that: Code: // positive integer I is given void factor(int I) { // P = 1 int P = 1; int mult; // while (I > 1) while (I > 1) { // P = P + 1 P = P+1; // what is this line for??? I = I/P; // if I mod P != 0 go back to previous statement // now what?

Related threads on "CodeGuru Forums - A Developer.com Community for C++, C#, VB, Java and .NET Solutions":

Related threads on other sites:

Thread profile page for "Help with factorize function" on http://www.codeguru.com. This report page is a snippet summary view from a single thread "Help with factorize function", located on the Message Board at http://www.codeguru.com. This thread profile page shows the thread statistics for: Total Authors, Total Thread Posts, and Thread Activity