Arrays - Reading Assignment

  1. Arrays let us take a list of strings/integers assigned to one variable.
  2. indexOf
1 Like
  1. What do arrays allow us to do?
    Arrays hold a list of values in one variable .
  2. What index should you use in order to access the first element in an array?
    Arrays are 0 indexed.
1 Like
  1. Arrays allow us to store and access multiple values - strings or integers - in a single variable [inside square brackets, separated by commas].
  2. Counting/indexing begins with zero in arrays.
1 Like

Arrays - Reading Assignment.

  1. Arrays allow us to do the following:
  • store multiple values in a single variable.

  • store a fixed-size sequential collection of elements of the same type.

  • store collection of data (variables of the same type)

    e.g var fruits = new Array(ā€œappleā€, ā€œmangoā€, ā€œorangeā€);

  1. IndexOf - is use in order to access the first element in an array.
1 Like

1. What do arrays allow us to do?
Arrays allow us to store multiple values of the same type in one place. You can view an array as a collection of variables that can store the same type of values. Instead of storing a lot of the same type in separate variables on the source code you can just store them all inside an array which will let you manipulate them more easily as a collection, using loops.

2. What index should you use in order to access the first element in an array?
0

1 Like
  1. the array object lets you store a collection of variables of the same type in a program.
  2. 0
1 Like
  1. What do arrays allow us to do?
    Store multiple values of the same type in a single variable

  2. What index should you use in order to access the first element in an array?
    Default 0

1 Like
  1. Allows us to index a set of values
  2. 0
1 Like

arrays allow us to store multiple values in a single variable

  1. when calling the first value of an array you will use the number 0 by default.
1 Like
  1. An Array is used to store data in a collection (or multiple values) of variables of the same type.
  2. To access the first element the index is 0.
1 Like
  1. The Array object lets you store multiple values in a single variable.
  2. arrayName[0]; // index 0
1 Like
  1. What do arrays allow us to do?
    An array is a way to have multiple values of the same time in one single variable which should be indexed to access to each of those values.

  2. What index should you use in order to access the first element in an array?
    0

1 Like
  1. What do arrays allow us to do?

An array is a variable object that can store multiple values of one type (althouth in other languages like Python, an array can store a value of any type).

  1. What index should you use in order to access the first element in an array?

Index 0.

1 Like
  1. What do arrays allow us to do?
    Arrays allow us to store multiple individual values in one variable…

  2. What index should you use in order to access the first element in an array?
    0 is always the first item in an array.

1 Like
  1. Arrays allow us to store multiple values in a single variable.
  2. Index 0.
1 Like
  1. What do arrays allow us to do?
    Arrays allow us to store multiple values under a single variable, they must be the same type of value however. An array can store a collection of values under a single variable for ease of access.

  2. What index should you use in order to access the first element in an array?
    Arrays start counting at 0 so to access the first element should be called using index [0]

1 Like
  1. Arrays allow us to store more than one value or object in a variable
  2. 0, You always start with 0, then 1 and so on.
1 Like
  1. Arrays allow us to store multiple values in a single variable. It stores a fixed-size sequential collection of elements of the same type. An array is used to store a collection of data, but it is often more useful to think of an array as a collection of variables of the same type.
  2. 0
1 Like

Array Reading Assignment Answers

  1. Arrays allow us to store multiple values, of the same data type in sequential order at a fixed size inside a single variable. Arrays are used to store a collection of data.

  2. the first element of an is 0 index.

1 Like
  1. Array object lets you store multiple values in a single variable.
  2. 0 is first element
1 Like