C Programming Tutorial 14, For Loop

preview_player
Показать описание

Рекомендации по теме
Комментарии
Автор

It doesn't skip it, it just executes i += 2 after it goes through the loop. So every time that it goes through the loop it does that statement after. If you still don't understand, then contact me on aim, my username is iTzAdam5.

iTzAdamX
Автор

@TurboBorsuk Did you do that thing at the beginning of the video? You've gotta type -std=c99 so that it will allow for loops.

iTzAdamX
Автор

@perriperripanpan I have no idea. For C, the only compiler I use is CodeBlocks.

iTzAdamX
Автор

"Alright, so let's just go ahead and run this and make sure that it works. Yepp !"

CelestialArchers
Автор

i didn't even need "-std=c99" this code,
it works without it,
and thanks, your tutorials are very helpful

NotesAndSoft
Автор

What exactly is the -std=c99 for? some module that 'for' loop is in that we have to import? great tuts btw man! Thanks! ;)

garyxxx
Автор

@kildas I have no idea what that is, lol, so no.

iTzAdamX
Автор

Do you plan to make some tutorials how to make RS232 or any serial communication using C

kildas
Автор

@arshak0023 I have no idea what that is, sorry.

iTzAdamX
Автор

Adam why in the for loop for (int i = 1; i< 50; i+=2) there is not need for a semi ; after i+=2?

thewhisperinyourears
Автор

Adam can you explain me why we need the C99 ? i know is the C version or something but why to include it? I thought C is now standarized

thewhisperinyourears
Автор

@arshak0023 No I don't but I'm assuming that winapi is for windows only, so do you know of a library that is cross platform? Because I would rather not teach something that will only work on windows.

iTzAdamX
Автор

I get: "error: 'for' loop initial declarations are only allowed in C99 mode" with "for (int i =..."
I remember you choosing gcc in the 1st tutorial which does not fully support C99.
Did you change anything in the meanwhile?

TurboBorsuk
Автор

@iTzAdam5X Eh, I might as well just use Codeblocks for this assignment. Anyway, thanks so much for taking the time to make these tutorials. They are helpful.

perriperripanpan
Автор

Sorry, it does work. I was typing, instead of ; in the for loop bracket.

FilipGereg
Автор

@iTzAdam5x im a little confused bro can you explain me y it skips i +- 2 when it goes through the loop the first time and the second time it goes through it until i < 50

nobazter
Автор

I can't figure out how to modify the compiler settings on Eclipse

perriperripanpan
Автор

i have in my settings compiler )alone), and debugger (alone). whats the solution in this case?

Tooprow
Автор

I'm using Cygwin to write my code. The txt editor I use is the one where you type "nano filename.c"

Do you know where I'm supposed to type the -std=c99 in this IDE

ProggyDrummer
Автор

-std=c99 doesn't work for me in Code::Blocks
I get this error:
C:\C Programming\main.c|6|error: 'for' loop initial declaration used outside C99 mode|

naruto