string eqaliser
this thing takes 2 strings and eqalises the lentghs. so for example u take "foo" and "foobar" an itll make "foo000" and "foobar" .
is very hi tech .
enjoy, (c) me
is very hi tech .
enjoy, (c) me
Code:
void fixstrign(char*& lol,char*& hue) {
//lengths for maximum efficiency of length
int lollen=strlen(lol);
int huelen=strlen(hue);
if(lollen==huelen) return;
bool swape=lollen<huelen; //swapemaster
if(swape) {
char* tmp=lol;lol=hue;hue=tmp;
int tmp2=lollen;lollen=huelen;huelen=tmp2;
}
//<br>
//is made a <br> above to add a line between the lines for to make a line taller
char* newhue;
newhue=new char[lollen];
memcpy(newhue,hue,huelen);
for(int i=huelen;i<lollen;++i)
newhue[i]='0';
hue=newhue;
//<br>
//more of this is <br>
if(swape) {
char* tmp=lol;
lol=hue;
hue=tmp;
}
}
