Deck 7: Using Object Oriented Javascript
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
Match between columns
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
فتح الحزمة
قم بالتسجيل لفتح البطاقات في هذه المجموعة!
Unlock Deck
Unlock Deck
1/41
العب
ملء الشاشة (f)
Deck 7: Using Object Oriented Javascript
1
The code for a method must be stored in an external function.
False
2
The ____ class contains methods and properties for manipulating the date and time.
A) Zone
B) Calendar
C) Date
D) Time
A) Zone
B) Calendar
C) Date
D) Time
C
3
When working with a date, JavaScript stores the month as a ____.
A) value from 0-11
B) value from 1-12
C) two-letter abbreviation
D)three-letter abbreviation
A) value from 0-11
B) value from 1-12
C) two-letter abbreviation
D)three-letter abbreviation
A
4
____ refers to cleaning up, or reclaiming, memory that is reserved by a program.
A) Information hiding
B) Garbage collection
C) Data collection
D) Object hiding
A) Information hiding
B) Garbage collection
C) Data collection
D) Object hiding
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
5
A(n)____ function is a function that is used as the basis for a custom object.
A) constructor
B) object
C) instance
D) class
A) constructor
B) object
C) instance
D) class
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
6
The code (methods and statements)and data (variables and constants)contained in an encapsulated object are accessed through a(n)____.
A) black box
B) view
C) interface
D) template
A) black box
B) view
C) interface
D) template
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
7
The ____ class contains methods for manipulating numbers and properties that contain static values representing some of the numeric limitations in the JavaScript language.
A) Integer
B) Number
C) Math
D) Limits
A) Integer
B) Number
C) Math
D) Limits
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
8
To delete a specific property in a custom object, you use the ____ operator.
A) remove
B) cancel
C) erase
D) delete
A) remove
B) cancel
C) erase
D) delete
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
9
The value of an object property can be another object.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
10
The code new Date() creates an empty Date object.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
11
To execute the same statement or command block for all the properties within a custom object, you can use the ____ statement.
A) for/each
B) while/in
C) for/in
D) loop/in
A) for/each
B) while/in
C) for/in
D) loop/in
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
12
You can use the Math object directly in your programs without instantiating a new object.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
13
The term ____ refers to information contained within variables or other types of storage structures.
A) data
B) object
C) class
D) instance
A) data
B) object
C) class
D) instance
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
14
A(n)____ is an object that has been created from an existing class.
A) instance
B) interface
C) template
D) black box
A) instance
B) interface
C) template
D) black box
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
15
You can create a function that will be used as an object method by referring to any object properties it contains with the ____ reference.
A) self
B) this
C) super
D) object
A) self
B) this
C) super
D) object
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
16
The ____ class contains methods and properties for performing mathematical calculations in your programs.
A) Number
B) Integer
C) Function
D) Math
A) Number
B) Integer
C) Function
D) Math
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
17
A(n)____ array is an array whose elements are referred to with an alphanumeric key instead of an index number.
A) parallel
B) class
C) associative
D) bidimensional
A) parallel
B) class
C) associative
D) bidimensional
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
18
Objects are also called ____.
A) data
B) functions
C) methods
D) components
A) data
B) functions
C) methods
D) components
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
19
The ____ property is a built-in property that specifies the constructor from which an object was instantiated.
A) experiment
B) try
C) prototype
D) test
A) experiment
B) try
C) prototype
D) test
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
20
You can create an empty object by assigning a pair of empty braces to a variable name.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
21
Which Number class method can you use to convert a number to a string that is formatted with local numeric formatting style?
A)toFixed()
B)toLocaleString()
C)toPrecision()
D)toString()
A)toFixed()
B)toLocaleString()
C)toPrecision()
D)toString()
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
22
You can create an empty object by assigning a pair of empty __________ to a variable name.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
23
Match between columns
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
24
Which class requires you to use a constructor?
A) Math
B) Number
C) Date
D) Array
A) Math
B) Number
C) Date
D) Array
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
25
How can you get the full text of the day of the week based on information retrieved from a Date object?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
26
Describe two ways of adding properties to an object.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
27
What is a sub-object? Provide an example.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
28
When creating an object using a literal, you separate multiple property-value pairs with ____.
A)colons
B)spaces
C)semicolons
D)commas
A)colons
B)spaces
C)semicolons
D)commas
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
29
You can append the name of any Number class method or property to the name of an existing variable that contains a(n)____________________ value.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
30
How do you declare a property within an object literal?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
31
Which method of the Math object rounds a value to the next lowest integer?
A)ceil()
B)floor()
C)max()
D)min()
A)ceil()
B)floor()
C)max()
D)min()
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
32
What are some of the benefits of encapsulation?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
33
Explain the difference between the Number and Math classes.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
34
Why is JavaScript said to be an object-based programming language?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
35
What is garbage collection and how is it performed in JavaScript apps?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
36
To add a property to a constructor function, you must add a statement to the function body that uses the ____ keyword.
A)NaN
B)function
C)this
D)property
A)NaN
B)function
C)this
D)property
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
37
The principle of ____________________ states that any methods and properties that other programmers do not need to access or know about should be hidden.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
38
A particular instance of an object ____________________ its methods and properties from a class-that is, it takes on the characteristics of the class on which it is based.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
39
____________________ refers to the creation of reusable software objects that can be easily incorporated into multiple programs.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
40
If you assign the current date and time to a variable, what is the value of that variable one hour later? Explain.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck
41
Describe two ways of adding a method to an object.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 41 في هذه المجموعة.
فتح الحزمة
k this deck