Untitled

mail@pastecode.io avatar
unknown
javascript
a year ago
558 B
2
Indexable
Never
const randomValues = [
  ['value 1 of 1', 'value 2 of 1', 'value 3 of 1'],
  ['value 1 of 2', 'value 2 of 2', 'value 3 of 2'],
  ['value 1 of 3', 'value 2 of 3', 'value 3 of 3']
];

// For each item in this randomValues array ----
for (let outer = 0; outer < randomValues.length; outer++) {
  // For each item in the inner array
  // randomValues[1]
  for (let inner = 0; inner < randomValues[outer].length; inner++) {
    // Send out a ramadan gift notification for those fasting
    console.log('This is the inner value', randomValues[outer][inner]);
  }
}