Logo

Programming-Idioms

This language bar is your friend. Select your favorite languages!
  • Ada
for E of x loop
   S := S + E;
end loop;

x is an array.
S is initialized to be 0.
int i,s;
for(i=s=0;i<n;i++)
{
	s+=x[i];
}

x is an array with size n.

New implementation...
< >
deleplace