before i explain my problem i'll give you what i've got so far
now as you can probably gather i'm trying to make a function out of the code above and i think i've got it but when i compile i get an error on theCode:#include <windows.h> #include <iostream> using namespace std; int question ( string usr_name ); int main() { string usr_name; cout<<"hello enter a name: "; cin>> usr_name; cin.ignore(); cout<<"ok so your name is "<< question ( usr_name ); Sleep (20000); } int question ( string usr_name ) { return usr_name; }part of it, i've scanned tutorials but i can't find my problem or how to solve it, i realize this is probably some basic problem involving a misplaced semicolon or somethiing but i'd appreciate it if someone can help me out with the problem anyhow. thanks in advanceCode:{ return usr_name; }



LinkBack URL
About LinkBacks


