Can i use foreach instead of for when loops all the array? | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
+ 1

Can i use foreach instead of for when loops all the array?

I have used foreach for this case on another languages, is the same on c#?

21st Feb 2017, 12:16 AM
degreerichi
degreerichi - avatar
2 Respostas
+ 1
It works just the same, yes.
21st Feb 2017, 12:50 AM
Sebastian Grigor
Sebastian Grigor - avatar
+ 1
thanks!
21st Feb 2017, 1:04 AM
degreerichi
degreerichi - avatar