Latest Activity In Study Groups

Join Your Study Groups

VU Past Papers, MCQs and More

We non-commercial site working hard since 2009 to facilitate learning Read More. We can't keep up without your support. Donate.

Asalam o ALikum!

yrrrrrr agar kisi ny first lecture lia tu us ma jo refactor kia program ko us ma error a raha koi help kr dy. code nichy dy raha hon es ma error dy raha k [Error] 'f' was not declared in this scope:

ya kon sy scope ka error ha koi help kr dy plzzzz

#include <iostream>
#include <fstream>
int onkeypress()
char b = std::cin.get();
std::cout b std::endl;
return b == 'x';
int onfilechanged()
char a = f.get();
std::cout a std::endl;
return a == 'x';
int main()
char a = '-', b;
do {
if (kbhit()) {
if (onkeypress())
return 0;
std::ifstream f("test.txt", std::ifstream::in);
if (f.good() && a != f.peek()) {
if (onfilechanged())
return 0;
} while (true);
return 0;

Views: 58

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

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