C++ Can you guys help me fix that code? It's supposed to be a calendar, but there seem to be some syntax errors? :/ EDIT: there is the exact error http://screencast.com/t/SFhC7bIRw
@timo86m @Hero @zepdrix @robtobey @Mertsj @jim_thompson5910 @modphysnoob
what's was exact error?
undeclared identifiers
it doesn't say line number
what do you mean?
usually it will say undeclared identifier and something else too
...
well it says that main must return int, so just try writing int main(){ //all code return 0; }
I already did that @Tomas.A but its behavior is not as expected right now
what's wrong? i have actually compiled code myself and it seems to work fine (except for certain leap years as you probably know yourself)
did you find this code by googling..? lol
Did you compile it? Using which compiler?
@Tomas.A
g++ 4.4.3
Can you give me the cpp please
i just changed void main to int main and at the end of main added return 0
please tell me where exactly
at the end of main function
I might as well doing a mistake at the location for all it matters lol
actually it doesnt really matter its working even without adding return 0 its just a nice practice but if you added it at random place it might break something
why dont you try to write code yourself?
Dud that G++ is on linux? I cant get it to work on Visual studio so many undeclared identifiers with no particular reason
yes its on linux but you can get it on windows as well also i didn't mention obvious thing that i removed this line "#include "stdafx.h"" also your teacher can easily notice that you copied it from internet (if he cares)
i can help u in c++ but give the code i'll have to write it all
Join our real-time social learning platform and learn together with your friends!