Hi really new to javascript and am hoping to get some help with a problem im facing.
So I basically have an array that stores objects. Each object contains an id and a variable i which is a number. My question is this: how can I extract the value of i from the object array with the id value? The id that I am using would already have been stored in the array with an i value.
var i = 1;
var id;
var b = {}; 
var y = [];
if(condition) {
  b = {"123":i};
  y.push(b);
}
if(condition) {
  id = 123;
  //Find corresponding i value for id "123" from object array y
  i = ?;
}
 
     
     
     
     
    