[RESOLVED] Code not working - help
The "assigns" in the following code is not working. I don't know if assigns is what i should be using. I need to retrieve characters from line1. The variables: last, xxpos, eqpos contain certain position numbers in string line1. Any help is much appreciated. Thanks.
getline( reader , line1 ) ;
last = line1.length() ;
xxpos = line1.find( "x", 0 ) ;
eqpos = line1.find( "=", 0 ) ;
num1.assign( 0, line1.at(xxpos) - 1 ) ;
numx.assign( line1.at(xxpos), line1.at(xxpos) ) ;
num2.assign( line1.at(xxpos) + 1, line1.at(eqpos) - 1 ) ;
numeq.assign( line1.at(eqpos), line1.at(eqpos) ) ;
num3.assign( line1.at(eqpos) + 1, line1.at(last) - 1 ) ;
Re: Code not working - help