What do you mean "the number of sequences"? Please give an example number and explain what you would expect the result to be. Did you give it a try? You'll get much better replies if you ask a specific question about a problem you're having rather than just asking for the whole algorithm.
I have mostly everything figured out except the loop. I can't seem to get it quite right.
using namespace std;
int partition(int n, int max)
int ret = 0;
cout << "Enter a number: " << endl;
cin >> n >> endl;
Yea your right, I calculated the mapping of each n wrong. Tried to do it with the correct value and didn't come with a definite answer, although I got an approximation. Anyways. Thanks for the correction.
This is actually a very difficult problem. As far as i am aware it was solved by the prolific mathematician Leonard Euler. It relates to pentagonal numbers(don't know why). I have the code for your problem if you want it, but i will not post it now in case you want to get this thing by yourself. I will pm it if you ask.
Hi I'm having a problem implementing a mini shopping cart drop down in the header to show the user all the products they have in their shopping cart. It seems the only solution for this is Ajax, and I've looked all over and can't find anything that I could possibly ...
Help! I want to create a java program that finds the highest even integer among the values entered by the user. Stop asking values when a value less than 1 have been entered. If no even integer is entered, display "No Even Integer"