HELP MEH /b/!
I was here before a month, again with a simple c++ question, so here i am again.
WHY do i get errors on that?!
>>675303894
What kind of errors?
error is between chair and monitor
You need a semi-colon after the loop
is compiler side error
>>675304359
Do you even computer?
OP here, its the compiler's error... It wont even run properly an empty *.cpp file
Using CodeLite btw
>>675303894
Because you're using a shitty IDE that uses what ever the fuck this is instead of tabs
This is how I would do it:
cpp.sh/2qch4
This also works:
cpp.sh/9d76
the \n is an escape character to add a new line at the end of the literal string. Maybe you're forgetting that.
Running your code:
cpp.sh/4oll
>>675304359
No you don't
>>675304625
Try to save file
>>675304651
it displays tabs so you can yell at the jackass who uses spaces.
suggest me a good IDE + compiler
Why the fuck you Dearing I=0 above the for loop
>>675304985
I use VS but if you don't like M$ use code::blocks for windows.
For linux use:
$ nano <file.cpp>
$ g++ file.cpp -o compiled
$ ./compiled
Declaring
in linux that don't happend
You declare I to be 5 at the beginning of each loop. It won't increment like that. I++ changes I.
>>675303894
Because you touch yourself.
Tab the loop again
in linux does not happen
>>675305650
kill yourself
>>675303894
Post the error you're getting or get the fuck out.
What is wrong with VS 2013 Community?
>inb4 empty arguments about microsoft is an evil corperation that is trying to figure out when you're fapping
>>675306040
bump for common sense,
also tits if femanon
Idk, just declare the int inside the for loop
>>675306229
It's too heavy
tfw none of you know basic C++
>>675307095
what now. Basic or C++?
;^)
>>675303894
cout is an undeclared variable. I have no idea what "<<" is, but if you're trying to say "fuck yes" 4 times then you just need a print statement. If this is C++ then you don't need a return statement in your main.
try including <bits/stdc++.h>
>>675307283
yes
>>675307349
Correction, It'll say "fuck yes" 6 times with this loop.
You're all dummies
What error?
>>675306229
I KEKED
>>675305162
>nano
>>675307349
cout isnt an undeclared variable you autist. Learn C++ before trying to help somebody.
>>675303894
what a fucking retard, the c++ syntax literally tells you waht you did wrong, do something useful and learn haskell you pleb
>>675304263
Underrated
>>675303894
cuz it's got an std
>>675307808
use to coding in C. Like I said I have no idea what << does.
>>675307654
real programmers use ed
found a pic of OP
>>675305148
this
>>675303894
You declare i=0
The loop begins when i=5, which it never does so it never enters the loop.
To make it work type for(int i=5; i<=10; i++) and remove the int i=0 above and you'll be fine.
Because you've declared int as 0, and then try to i=5, i<=10, 1++
how can it enter the loop if it never reaches 5 nigga?
>>675308187
no, the first expression sets the variable, the second expression is the loop condition, and the third is the loop iteration
declaring i beforehand is unnecessary in c++, but it doesn't change the behavior of for
>>675308510
Doesn't C++ allow for an int to be declared with no value? Pretty sure it does.
>>675308187
Excellent plinegrat subduction with this one. You can tell the designer knew full well what he was doing with that .75 of a plinegrat on the top corners. Because of this, I'm willing to bet this is the work of Schlosser. I know I'll get flamed when I say I don't believe his was a complete master of Plinegrat Subduction, but he comes in a close second behind Fulier.
>>675304263
Undercrated boats
Closing parentheses come before return. Not aftrr.
>>675309584
wrong
>>675308716
Yoy dont even need to declare the "i" before to do the loop.
The i from inside de condition isnt the same as the other.