O'Reilly logo

JavaScript and JSON Essentials by Sai Srinivas Sriparasa

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Performing complex operations

To tackle an array of objects, we have to handle them in an iterative method. We will have to come up with an iterative solution in which we target one object at a time; once the object is accessed, we would not target that object another time. This allows us to maintain data integrity as we can avoid accessing the same object multiple times, thereby avoiding any redundancies. The looping statements in JavaScript are the while loop and the for loop. Let us take a quick look at how we can use these looping techniques to traverse through our employees' array.

Performing complex operations

In the while_employees_traversal.html file, we are importing ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required