I have one file that contains the following information:
5 REM Calculating the n factorial, n!
15 PRINT " Enter a positive integer number:"
20 INPUT n
30 LET fact = 1
40 IF n <= 1 THEN 80
55 LET fact = fact * n
60 LET n = n - 1
70 GOTO 40
80 PRINT fact
Okay I want to get each individual line so I can push into a stack. However if I do this:
ifstream fin;
inpF.open("basic.txt");
string read;
while(!fin.eof())
{/***Read Line by Line until end of file***/
fin >> read;
if(!unRead.isFull()) unRead.push(read);
}
How can I read one line?
5 REM Calculating the n factorial, n!
15 PRINT " Enter a positive integer number:"
20 INPUT n
30 LET fact = 1
40 IF n <= 1 THEN 80
55 LET fact = fact * n
60 LET n = n - 1
70 GOTO 40
80 PRINT fact
Okay I want to get each individual line so I can push into a stack. However if I do this:
ifstream fin;
inpF.open("basic.txt");
string read;
while(!fin.eof())
{/***Read Line by Line until end of file***/
fin >> read;
if(!unRead.isFull()) unRead.push(read);
}
How can I read one line?