You made a typo, wrote int maim(void) instead of int main(void). In
addition you made mistakes (e.g. forgot the "do" in do-while). Also you
code in preANSI C++ style. I do not know what you wanted to do so i made
it to have some basic logic. Your code fixed and ANSI C++ compliant:
/*This program verifies data.
Jac Lyn Owenby
280-01 Prog 1
*/
#include <iostream>
int main(void)
{
using namespace std;
//Declarations
int num1;
int num2;
int num3;
int num;
//Statements
cout << "\nPlease enter data to be validated." <<endl;
while(cin>> num >> num1 >> num2 >> num3)
;
return 0;
}
The above code written in a better way:
/*This program verifies data.
Jac Lyn Owenby
280-01 Prog 1
*/
#include <iostream>
int main()
{
using std::cin;
using std::cout;
using std::endl;
//Declarations
int num1, num2, num3, num;
//Statements
cout << "\nPlease enter data to be validated." <<endl;
while(cin>> num >> num1 >> num2 >> num3)
;
}
Ioannis
* Ioannis Vranos
* Programming pages: http://www.noicys.d2g.com
* Alternative URL: http://run.to/noicys
> -----Original Message-----
> From: dev...@li...
> [mailto:dev...@li...] On Behalf
> Of w0058498
> Sent: Monday, January 28, 2002 7:44 PM
> To: CPP-Maillinglist (E-Mail)
> Subject: [Dev-C++] Linker Problem
>
>
> This is probably an elementary problem; however, I have only
> been using Dev
> C++ for a short time and writing code is a little confusing. I'm
> C++ writing code
> that validates numerical data. When I run my program, I come
> up with a linker
> problem. Can anyone please help?
>
> Thanks
> Jac Lyn
>
>
|