Thread: C++ Help
View Single Post
Old 10-6-2005, 08:35 PM   #33
chickendude
Away from Computer
FFR Simfile AuthorFFR Veteran
 
chickendude's Avatar
 
Join Date: Sep 2003
Location: Massachusetts
Age: 35
Posts: 1,901
Send a message via AIM to chickendude
Default RE: Re: RE: Re: C++ Help

Code:
#include <iostream>
main()
{
 int x,y;

 cout << "enter an x and a y";
 cin >> x;
 cin >> y;
 if x==0 && y==0
    cout << "origin";
 if x==0 && y!=0
    cout << "y-axis";
 if y==0 && x!=0
    cout << "x-axis";
 if x > 0 && y > 0
    cout << "first quadrant";
 if x < 0 && y > 0
    cout << "second quadrant";
 if x<0 && y<0
    cout << "third quadrant";
 if x>0 && y<0 
    cout << "fourth quadrant" ;
}
did I win?


Edit for bad include syntax <_<
__________________
chickendude is offline   Reply With Quote