I am a newbie seeking to learn C++. I have a book which gives many examples and concepts to play with. One of the first examples of the book does not compile using Quincy 2005. Is this a fault of the code or the IDE?
The example is here:
#include <stdio.h>
void main (){
int date = 10, d2=15;
float temp = 45.0, t2=33.5;
printf("On Dec. %d, temperature was %f.\n", date, temp);
printf("On Jan. %d, temperature was %f.\n", d2, t2);
}
Unfortunately, the IDE states that ::main must return an integer. Any ideas?
The example looks more like C, is this simply out of date?