function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Hadi MohammadiHadi Mohammadi 

Why we can not use int in "for" clause in apex?

Hello, I'm a newbie to the Salesforce platform. 
Can anybody say why we can not use "int" in "for" clause and we have to use Integer in it?
for example 
for (Integer i = 0 ; i < 200; i++) { ... } is correct but 
for (Integer i = 0 ; i < 200; i++) { ... }  is wrong.
Best Answer chosen by Hadi Mohammadi
Waqar Hussain SFWaqar Hussain SF
Word Integer is the correct premitive data type of Salesforce apex. Salesforce does not recognize int as integer.