- 1

What does the variable "i" stands for?

6th Jul 2018, 9:19 AM
Ella Marie Moises
Ella Marie Moises - avatar
3 Antworten
+ 2
From what I know C++ doesn't have a predefined variable called i. I think you mean the variable i that is used in for loops. It is used because it's shorter for iterator and you don't have to worry if you declared it for something else (except when you have nested loops in which case j is used). But i is mostly used because we got used to it. There's no rule telling you to use it. You can use any name you want
6th Jul 2018, 9:24 AM
Alexandru Turculet
Alexandru Turculet - avatar
0
iterator But any other variable name will also do, as long if it is no reserved keyword
6th Jul 2018, 9:25 AM
Matthias
Matthias - avatar
0
From "Integer". Or "Index". Is is used as an index. Also in mathematics, it is used in sigma notation.
6th Jul 2018, 9:29 AM
Disvolviĝo;
Disvolviĝo; - avatar