mugs
Lifer
- Apr 29, 2003
- 48,920
- 46
- 91
Originally posted by: Descartes
Are you people flipping serious, or are you just not developers? If not then I understand, and that's ok...
Absolutely serious and I am a developer.
Originally posted by: Descartes
Are you people flipping serious, or are you just not developers? If not then I understand, and that's ok...
Originally posted by: Descartes
Originally posted by: BlueFlamme
Originally posted by: Descartes
That's not a 2-d array.
int stupidarray[4][3];
stupidarray[0][0] = 3;
stupidarray[0][1] = 1;
stupidarray[0][2] = 6;
...
stupidarray[3][0] = 5;
stupidarray[3][1] = 3;
stupidarray[3][2] = 7;
Maybe I've been away from code for too long, my last programming course did not require us to write a single line of code. Instead it was dealing with proofs of big O and Omegas of things like quicksort and that crap.
That's fine, now print and out and tell me what you expect it to look like. Perhaps I'm just looking at its printed representation differently than others in this thread, but I don't see how that's possible.
Originally posted by: DAGTA
Originally posted by: Descartes
Originally posted by: DAGTA
Originally posted by: xospec1alk
Originally posted by: Gibson486
Originally posted by: Descartes
Originally posted by: stan394
Originally posted by: Gibson486
Originally posted by: stan394
what does 'sorting a 2-dimension array' mean? i mean, i had a hard time picturing what is supposed to be the 'right' behavior.
you have an X and a Y
hm.. let's say you have this 2-dimensional array
3 8 7 5
1 2 5 3
6 4 9 7
what does it look like after you sort it?
That's not a 2-d array.
x and y, what more do you want?
it has more than two dimensions....
It does? I'm waiting for you or Descartes to explain.
Assuming each digit in the above examples represent a discrete item in the array I think it should be obvious. If they are not discrete then you have a one-dimensional array, and if they are discrete you have a four-dimensional.
Either way it's not a two-dimensional.
Wow... and to think... you make more money than me....
Originally posted by: Descartes
Originally posted by: BlueFlamme
Originally posted by: Descartes
That's not a 2-d array.
int stupidarray[4][3];
stupidarray[0][0] = 3;
stupidarray[0][1] = 1;
stupidarray[0][2] = 6;
...
stupidarray[3][0] = 5;
stupidarray[3][1] = 3;
stupidarray[3][2] = 7;
Maybe I've been away from code for too long, my last programming course did not require us to write a single line of code. Instead it was dealing with proofs of big O and Omegas of things like quicksort and that crap.
That's fine, now print and out and tell me what you expect it to look like. Perhaps I'm just looking at its printed representation differently than others in this thread, but I don't see how that's possible.
Originally posted by: Descartes
Originally posted by: BlueFlamme
Originally posted by: Descartes
That's not a 2-d array.
int stupidarray[4][3];
stupidarray[0][0] = 3;
stupidarray[0][1] = 1;
stupidarray[0][2] = 6;
...
stupidarray[3][0] = 5;
stupidarray[3][1] = 3;
stupidarray[3][2] = 7;
Maybe I've been away from code for too long, my last programming course did not require us to write a single line of code. Instead it was dealing with proofs of big O and Omegas of things like quicksort and that crap.
That's fine, now print and out and tell me what you expect it to look like. Perhaps I'm just looking at its printed representation differently than others in this thread, but I don't see how that's possible.
Originally posted by: Descartes
Originally posted by: DAGTA
Originally posted by: Descartes
Originally posted by: DAGTA
Originally posted by: xospec1alk
Originally posted by: Gibson486
Originally posted by: Descartes
Originally posted by: stan394
Originally posted by: Gibson486
Originally posted by: stan394
what does 'sorting a 2-dimension array' mean? i mean, i had a hard time picturing what is supposed to be the 'right' behavior.
you have an X and a Y
hm.. let's say you have this 2-dimensional array
3 8 7 5
1 2 5 3
6 4 9 7
what does it look like after you sort it?
That's not a 2-d array.
x and y, what more do you want?
it has more than two dimensions....
It does? I'm waiting for you or Descartes to explain.
Assuming each digit in the above examples represent a discrete item in the array I think it should be obvious. If they are not discrete then you have a one-dimensional array, and if they are discrete you have a four-dimensional.
Either way it's not a two-dimensional.
Wow... and to think... you make more money than me....
A lot more I'm sure. What's your point?
Originally posted by: Descartes
Originally posted by: DAGTA
Originally posted by: xospec1alk
Originally posted by: Gibson486
Originally posted by: Descartes
Originally posted by: stan394
Originally posted by: Gibson486
Originally posted by: stan394
what does 'sorting a 2-dimension array' mean? i mean, i had a hard time picturing what is supposed to be the 'right' behavior.
you have an X and a Y
hm.. let's say you have this 2-dimensional array
3 8 7 5
1 2 5 3
6 4 9 7
what does it look like after you sort it?
That's not a 2-d array.
x and y, what more do you want?
it has more than two dimensions....
It does? I'm waiting for you or Descartes to explain.
Assuming each digit in the above examples represent a discrete item in the array I think it should be obvious. If they are not discrete then you have a one-dimensional array, and if they are discrete you have a four-dimensional.
Either way it's not a two-dimensional.
Originally posted by: Descartes
[That's fine, now print and out and tell me what you expect it to look like. Perhaps I'm just looking at its printed representation differently than others in this thread, but I don't see how that's possible.
Originally posted by: five40
Originally posted by: Descartes
Originally posted by: BlueFlamme
Originally posted by: Descartes
That's not a 2-d array.
int stupidarray[4][3];
stupidarray[0][0] = 3;
stupidarray[0][1] = 1;
stupidarray[0][2] = 6;
...
stupidarray[3][0] = 5;
stupidarray[3][1] = 3;
stupidarray[3][2] = 7;
Maybe I've been away from code for too long, my last programming course did not require us to write a single line of code. Instead it was dealing with proofs of big O and Omegas of things like quicksort and that crap.
That's fine, now print and out and tell me what you expect it to look like. Perhaps I'm just looking at its printed representation differently than others in this thread, but I don't see how that's possible.
Being a developer for 15+ years...you have NO IDEA what a 2d array is. What everyone has said is a 2d array is a 2d array. What BlueFlamme input is a 2d array.
hm.. let's say you have this 2-dimensional array
3 8 7 5
1 2 5 3
6 4 9 7
Originally posted by: PingSpike
I'm not advanced programmer or anything...but wasn't what stan394 posted a 2-D array? I can't see why it isn't. I've only taken intro c++ and done a lot of game scripting so don't take what I'm saying as some master level programming knowledge here.
Edit: Wait I see. Its been awhile....
And "use the compare function"? What does that mean...does that even do the sorting? Isn't that just a piece of the code you might use to sort it?
This almost sounds like a question like "Whats the best way to build a boat?". Without any other specifics or constraints it seems like the only answer you could offer is more of an opinion then a fact.
Originally posted by: BlueFlamme
Originally posted by: Descartes
[That's fine, now print and out and tell me what you expect it to look like. Perhaps I'm just looking at its printed representation differently than others in this thread, but I don't see how that's possible.
It it just in the vizualiation imo. If you consider the first array as a column and the second array as the row then you can print out the rows followed by an endl with some code like the following:
for(i = 0, i <2, i++){
for(j = 0, j < 3, j++){
cout<<stupidarray[j]<<' ';
}
cout<<endl;
}
would yield the original array he proposed. Yeah, i screwed up the typical ordering of row then column, just view it as similar to a poetic license for coding.
Originally posted by: PingSpike
I'm not advanced programmer or anything...but wasn't what stan394 posted a 2-D array? I can't see why it isn't. I've only taken intro c++ and done a lot of game scripting so don't take what I'm saying as some master level programming knowledge here.
And "use the compare function"? What does that mean...does that even do the sorting? Isn't that just a piece of the code you might use to sort it?
This almost sounds like a question like "Whats the best way to build a boat?". Without any other specifics or constraints it seems like the only answer you could offer is more of an opinion then a fact.
Originally posted by: Descartes
Hello ignoramus, read my post. I didn't say what he presented was NOT a 2d array. I was referring to the printed example earlier.
Originally posted by: stan394
Originally posted by: Gibson486
Originally posted by: stan394
what does 'sorting a 2-dimension array' mean? i mean, i had a hard time picturing what is supposed to be the 'right' behavior.
you have an X and a Y
hm.. let's say you have this 2-dimensional array
3 8 7 5
1 2 5 3
6 4 9 7
what does it look like after you sort it?
Originally posted by: Howard
I stll don't understand how it's not a 2D array...
Originally posted by: Descartes
Originally posted by: five40
Originally posted by: Descartes
Originally posted by: BlueFlamme
Originally posted by: Descartes
That's not a 2-d array.
int stupidarray[4][3];
stupidarray[0][0] = 3;
stupidarray[0][1] = 1;
stupidarray[0][2] = 6;
...
stupidarray[3][0] = 5;
stupidarray[3][1] = 3;
stupidarray[3][2] = 7;
Maybe I've been away from code for too long, my last programming course did not require us to write a single line of code. Instead it was dealing with proofs of big O and Omegas of things like quicksort and that crap.
That's fine, now print and out and tell me what you expect it to look like. Perhaps I'm just looking at its printed representation differently than others in this thread, but I don't see how that's possible.
Being a developer for 15+ years...you have NO IDEA what a 2d array is. What everyone has said is a 2d array is a 2d array. What BlueFlamme input is a 2d array.
Hello ignoramus, read my post. I didn't say what he presented was NOT a 2d array. I was referring to the printed example earlier.
Originally posted by: Descartes
Originally posted by: BlueFlamme
Originally posted by: Descartes
[That's fine, now print and out and tell me what you expect it to look like. Perhaps I'm just looking at its printed representation differently than others in this thread, but I don't see how that's possible.
It it just in the vizualiation imo. If you consider the first array as a column and the second array as the row then you can print out the rows followed by an endl with some code like the following:
for(i = 0, i <2, i++){
for(j = 0, j < 3, j++){
cout<<stupidarray[j]<<' ';
}
cout<<endl;
}
would yield the original array he proposed. Yeah, i screwed up the typical ordering of row then column, just view it as similar to a poetic license for coding.
Thank you for kind and very accurate reply. You have summarized my thoughts, what I attempted to convey, etc. without doing so condescendingly.
This is all I meant to say. Don't know why it incited such a riot. Guess a lot of people have it out for me.
Originally posted by: Descartes
Originally posted by: BlueFlamme
Originally posted by: Descartes
[That's fine, now print and out and tell me what you expect it to look like. Perhaps I'm just looking at its printed representation differently than others in this thread, but I don't see how that's possible.
It it just in the vizualiation imo. If you consider the first array as a column and the second array as the row then you can print out the rows followed by an endl with some code like the following:
for(i = 0, i <2, i++){
for(j = 0, j < 3, j++){
cout<<stupidarray[j]<<' ';
}
cout<<endl;
}
would yield the original array he proposed. Yeah, i screwed up the typical ordering of row then column, just view it as similar to a poetic license for coding.
Thank you for kind and very accurate reply. You have summarized my thoughts, what I attempted to convey, etc. without doing so condescendingly.
This is all I meant to say. Don't know why it incited such a riot. Guess a lot of people have it out for me.
Originally posted by: BigJ
Originally posted by: Descartes
Hello ignoramus, read my post. I didn't say what he presented was NOT a 2d array. I was referring to the printed example earlier.
What Gibson posted here?
Originally posted by: stan394
Originally posted by: Gibson486
Originally posted by: stan394
what does 'sorting a 2-dimension array' mean? i mean, i had a hard time picturing what is supposed to be the 'right' behavior.
you have an X and a Y
hm.. let's say you have this 2-dimensional array
3 8 7 5
1 2 5 3
6 4 9 7
what does it look like after you sort it?
How is that not a 2-dimnesional array? 3 rows by 4 columns?
Originally posted by: torpid
Originally posted by: BigJ
Originally posted by: Descartes
Hello ignoramus, read my post. I didn't say what he presented was NOT a 2d array. I was referring to the printed example earlier.
What Gibson posted here?
Originally posted by: stan394
Originally posted by: Gibson486
Originally posted by: stan394
what does 'sorting a 2-dimension array' mean? i mean, i had a hard time picturing what is supposed to be the 'right' behavior.
you have an X and a Y
hm.. let's say you have this 2-dimensional array
3 8 7 5
1 2 5 3
6 4 9 7
what does it look like after you sort it?
How is that not a 2-dimnesional array? 3 rows by 4 columns?
Well technically it's just a big string with spaces and carriage returns.
Originally posted by: mugs
Originally posted by: Howard
I stll don't understand how it's not a 2D array...
Because Descartes is choosing to ignore the obvious and interpret it in a way that he knows the person who posted it did not intend. He's nitpicking about the printed representation in an attempt to make himself look smarter.
