why is it that most tutorials don't put the right code in. Im using dev-C++ and practically all code that is written in a turorial doesn't work for me for instance this.
// Sample program
// IEA September 1995
// Reads values for the length and width of a rectangle
// and returns the perimeter and area of the rectangle.
#include <iostream.h>
void main()
{
int length, width;
int perimeter, area; // declarations
cout << "Length = "; // prompt user
cin >> length; // enter length
cout << "Width = "; // prompt user
cin >> width; // input width
perimeter = 2*(length+width); // compute perimeter
area = length*width; // compute area
cout << endl
<< "Perimeter is " << perimeter;
cout << endl
<< "Area is " << area
<< endl; // output results
} // end of main program
and i got it from this part of a tutorial
this site
im actually starting to think that devC++ is not a standard compiler and thats why most code that i get from tutorials dont work. Is this true. Is there a better compiler?