//my first attempted program in C++, just a GUI for my computers driver disk. #include <iostream> #include <string> using namespace std; int main () string printinfo = "Driver CD 0.1'\n'Created by Travis Paul Hesketh for Cyberpower Gamer Infinity custom. Press Quit to exit at any time."; cout << printinfo; /*printing the standard info (e.g Version and programmer, now onto serious stuff :)*/ /*Asking name and driver*/ int main () { char question[] = "Please, enter your first name: "; char greeting[] = "Welcome, "; char yourname [15]; cout << question; cin >> yourname; cout << greeting << yourname << "! Please select a driver to install and press the Return key."; } /*Finished asking name, now to show the input to select driver*/ { int i; cout << "Please enter a driver number: '\n' Press the 1 button to start installation of nVidia GeForce 9800GT 512MB Driver '\n' or '\n' Press the 2 button to start installation of RealTek HD Audio 7.1 Card Driver"; cin >> i; cout << "The value you entered is " << i; cout << ". Opening installer file." } { if 1 then int result; result = system (D:\Drivers\nvidia.exe); } { if 2 then int result; result = system (D:\Drivers\sound.exe); return 0; } |
//my first attempted program in C++, just a GUI for my computers driver disk. #include <iostream> #include <string> using namespace std; int main () { cout << "Driver CD 0.1'\n'Created by Travis Paul Hesketh for Cyberpower Gamer Infinity custom. "; /*printing the standard info (e.g Version and programmer, now onto serious stuff :)*/ /*Asking name and driver*/ cout << "Welcome, Travis"; cout << "Please select a driver to install and press the Return key."; /*Finished welcome, now to show the input to select driver*/ int i; cout << "Please enter a driver number: '\n' Press the 1 button to start installation of nVidia GeForce 9800GT 512MB Driver '\n' or '\n' Press the 2 button to start installation of RealTek HD Audio 7.1 Card Driver "; cin >> i; cout << "The value you entered is "; << i; cout << ". Opening installer file. "; } |
cout << "The value you entered is "; << i;
cout << "The value you entered is " << i;