for (int k = 0; k < 10; k++)
{ if(boyName[fileCount][babyCount].at(k)> boyName[fileCount][babyCount+1].at(k))
{
temp = boyName[fileCount][babyCount];
boyName[fileCount][babyCount] = boyName[fileCount][babyCount+1];
boyName[fileCount][babyCount+1] = temp;
}
}
someone tell me why this bit of code won't work?
i'm comparing strings and alphabetizing them (about 10000 stored in an array)
if k is initialized to 0 and it's not a for loop it'll run fine, and alphabetize it but only by the first letter.
>>1
Shit are you daft? Either use std::fucking::sort in <algorithm>, or use a goddamn set to store your fucking data. Seriously, what the fucking hell. It's not like your shitcanned sort "algorithm" (LOL SWITCH SORT) provides any performance gains.
Just shitcan what you have and use a real method of doing it. Fucking goddamn faggots, C++ IS NOT C.
C++ is a joke language created by Stroustroup to troll the community. Sadly, they took him seriously.
Name:
Anonymous2007-11-19 9:30
Can you at least say what is it not doing? Is it not compiling? not actually switching the two entries around? the if statement's evaluation always yields a true or false even when it shouldn't? what is going wrong?
It won't fix your problem but my first thought looking at your code was that assigning string objects around is INEFFICIENT!! use pointers.
Name:
Anonymous2009-02-25 7:36
Yields a true or false even when the balky Flexowriter required a delay between output characters to work right He just located instructions on the server side Not an easy task but nothing worthwhile ever really is way above your current skill level There is a good idea indeed Much like meeting people on a.
Name:
Anonymous2009-03-06 13:47
Provides the most complete and customer friendly hosting service on the Internet today.