Answer the following true & false questions: In order to reference an image usin
ID: 3913325 • Letter: A
Question
Answer the following true & false questions:
In order to reference an image using the images[ ] array, you must first create the array in your program.
True
False
A single JavaScript array can store values of different data types; for example the array named customer could store a customer’s address (a string) and their age (an integer).
True
False
You can create an array in JavaScript without specifying a size.
True
False
If you are writing JavaScript that must be compatible with older browsers; avoid using the while loop, since older browsers may not support it.
True
False
Your program will run faster, if it doesn’t have to create new array elements at runtime.
True
False
Explanation / Answer
Hi please find the answer
If you have any query please let me know first by comment i will give solutions
=============================================
1 - False
It is not necessary to create image[] array, you can also store array by using
var array={"Image1","Image2"}; or you can create Image[] array but its not necessary;
============================================================
2- True
Javascript array can hold a different variable because the array can be use as object and tha object hold any datatype and that variable is access by its index number
var array=["John","Deo", 25];
=================================================
3 - True
We can create array without specifying a size. we declare a array like this
var array = [10,30,40];
=================================================
4- False
Older browser and modern browser support while loop and the code which is not support by older broswer e should be avoided
=========================================================
5- True
Our program will run faster if it doesn't have to create new array element at runtime because at runtime we adding a new element , and this is a dynamic memory allocation at runtime so it take a time to add new element and allocate a memory into heap
====================================================================
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.