We have been working very hard since 2009 to facilitate in your learning Read More. We can't keep up without your support. Donate Now.

www.bit.ly/vucodes

+ Link For Assignments, GDBs & Online Quizzes Solution

www.bit.ly/papersvu

+ Link For Past Papers, Solved MCQs, Short Notes & More

Looking for Something at Site? Search Below

start trying, and help me completing this code. we still have time till tomorrow midnight.

#include <iostream>
#include <fstream>
#include <string>
/*open file with ifstream
use getline(infile, string); in while loop to read file line by line
save data in string and string to :istringstream iss (string)
tokenized data with delimiter " = ? \n" ignore space, =, ? and blank lines
use LL(1) parsing table with stack or just use stack
compare condition
output the data with your own userdefine function void ()
*/

using namespace std;

int main()
{
ifstream inFile("abc.txt");

if (inFile.fail()) {
cerr "Unable to open file for reading." endl;
exit(1);
}

string nextToken;
while (inFile >> nextToken) {
cout "Token: " nextToken endl;
}

inFile.close();

return 0;
}


+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)

+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)

+ Click Here to Search (Looking For something at vustudents.ning.com?)

+ Click Here To Join (Our facebook study Group)


Views: 1088

Replies to This Discussion

last date??

RSS

HELP SUPPORT

This is a member-supported website. Your contribution is greatly appreciated!

Today Top Members 

© 2020   Created by +M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service

.