I quickly made this program in DEV C++ and have a few errors, heres a little background info on the program, there is a program at my school that allows the teachers to spy and take over your computer whenever so I did a little snooping and found that the file that i want to rename in the program is the file that enables the teachers to do that so without further ado:

#include <cstdlib>
#include <iostream>
#include <stdio.h>

using namespace std;

int main(int argc, char *argv[])
    int answer
    cout << "Welcome to the Vision6 Dis/enabler" << endl;
    cout << "Made By C Square 93" << endl;
    cout << "Please answer the following question and press enter" << endl;
    cout << "Is Vision enable right now?" << endl;
    cin >> answer;
    if (answer == yes) {
          rename("C:\SETTINGS.exe", "C:\harharhar.exe");
          cout << "You May now close the program" << endl;
    if (answer == no) {
          rename("C:\harharhar.exe", "C:\SETTINGS.exe");
          cout << "You may now close the program" << endl;
          } else {
                 cout << "Next time answer yes or no" << endl;
    return EXIT_SUCCESS;

So can anyone help me?

9 Years
Discussion Span
Last Post by Ancient Dragon

doesn't vision disable all keyboard and mouse input? Is your teacher blind?
Upgrade to VC++ -- There is a (free) express edition.


In strings, the \ character is the first character of a pair, like \n, \t, etc. If you want a \ in a string you need to use \\.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.