Deck 13: Standard Template Library (STL) II
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
سؤال
فتح الحزمة
قم بالتسجيل لفتح البطاقات في هذه المجموعة!
Unlock Deck
Unlock Deck
1/50
العب
ملء الشاشة (f)
Deck 13: Standard Template Library (STL) II
1
The class pair has two constructors: the default constructor and a constructor with two parameters.
True
2
Every object of type pair has two data members, first and second, and these two data members are private.
False
3
Because the data members of an object of type pair are private, each object of type pair can directly access these data members in a program.
False
4
With the help of the function make_pair, we can create pairs without explicitly specifying the type pair.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
5
Elements in an associative container are automatically sorted according to some ordering criteria.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
6
Elements in an associative container are not sorted automatically.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
7
Both the containers set and multiset automatically sort their elements according to some sort criteria.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
8
The only difference between the containers map and multimap is that the container map allows duplicates, whereas the multimap container does not.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
9
The definition of the class implementing a specific container is contained in the header file.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
10
Nonmodifying algorithms do not modify the elements of the container.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
11
To make the generic algorithms flexible, the STL usually provides three forms of an algorithm using the mechanism of function overloading.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
12
The STL relational function objects can also be applied to containers.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
13
Predicates are special types of function objects that return Boolean values.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
14
The STL provides four insert iterators to insert elements at a destination.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
15
The functions generate and generate_n are used to generate elements and fill a sequence.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
16
The function remove is used to remove the elements from a sequence by using some criteria.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
17
The algorithm find_adjacent is used to find the first occurrence of consecutive elements that meet certain criteria.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
18
The algorithm reverse reverses the order of the elements in a given range.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
19
The algorithm count_if counts the occurrences of a given value in a given range satisfying a certain criterion.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
20
The algorithm maxi is used to determine the maximum of two values.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
21
The algorithm min is used to determine the minimum of two values.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
22
The first form of the function transform has three parameters.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
23
The second form of the function transform has three parameters.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
24
The algorithms includes (subset), set_intersection, set_union, set_difference, and set_symmetric_difference assume that the elements within each given range are not sorted.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
25
The algorithms accumulate, adjacent_difference, inner_product, and partial_sum are numerical functions and manipulate numeric data.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
26
With the help of the ____, two values can be combined into a single unit and, therefore, can be treated as one unit.
A) class tuple
B) class unit
C) class pair
D) class double
A) class tuple
B) class unit
C) class pair
D) class double
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
27
A function can return two values by using the ____.
A) class tuple
B) class pair
C) class double
D) class unit
A) class tuple
B) class pair
C) class double
D) class unit
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
28
The definition of the class pair is contained in the header file utility, thus, to use the class pair in a program, the program must include the following statement ____.
A) include <util/utility>
B) include <utility.h>
C) include <compat/utility>
D) include <utility>
A) include <util/utility>
B) include <utility.h>
C) include <compat/utility>
D) include <utility>
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
29
The general syntax to declare an object of type pair is ____.
A) pair<Type1, Type2> pElement;
B) pair pElement<Type1, Type2>;
C) pair.{Type1, Type2} pElement;
D) pair{Type1, Type2} pElement;
A) pair<Type1, Type2> pElement;
B) pair pElement<Type1, Type2>;
C) pair.{Type1, Type2} pElement;
D) pair{Type1, Type2} pElement;
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
30
The statement ____ assigns 50 to the data member first of x.
A) x.first(50);
B) x.first = 50;
C) first(x) = 50;
D) x.value("first") = 50;
A) x.first(50);
B) x.first = 50;
C) first(x) = 50;
D) x.value("first") = 50;
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
31
The header file ____ contains the definition of the function template make_pair.
A) utils
B) atl2
C) atl_utility
D) utility
A) utils
B) atl2
C) atl_utility
D) utility
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
32
The default ordering criterion for the elements in an associative container is the relational operator ____.
A) >=
B) <=
C) >
D) <
A) >=
B) <=
C) >
D) <
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
33
A convenient and fast way to implement an associative container data structure is to use a ____.
A) linked list
B) binary search tree
C) priority queue
D) hash table
A) linked list
B) binary search tree
C) priority queue
D) hash table
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
34
The containers map and multimap manage their elements in the form ____.
A) key/pair
B) name/value
C) value/pair
D) index/key
A) key/pair
B) name/value
C) value/pair
D) index/key
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
35
The ____ contains algorithms that only look at the elements in a container and that move the elements of a container.
A) ATL
B) DTL
C) ASTL
D) STL
A) ATL
B) DTL
C) ASTL
D) STL
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
36
Modifying algorithms that change the order of the elements, not their values, are also called ____.
A) polymorphic algorithms
B) associative algorithms
C) compensating algorithms
D) mutating algorithms
A) polymorphic algorithms
B) associative algorithms
C) compensating algorithms
D) mutating algorithms
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
37
A ____ contains a function that can be treated as a function using the function call operator, ().
A) function object
B) reference object
C) property object
D) value object
A) function object
B) reference object
C) property object
D) value object
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
38
The first form of ____ uses the equality criteria.
A) adjacent_search
B) adjacent_query
C) adjacent_find
D) adjacent_criteria
A) adjacent_search
B) adjacent_query
C) adjacent_find
D) adjacent_criteria
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
39
The algorithm ____ merges the sorted lists.
A) combine
B) merge
C) resort
D) concatenate
A) combine
B) merge
C) resort
D) concatenate
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
40
The algorithm ____ reverses the elements of a given range while copying into a destination range.
A) copy_reverse
B) inverse_copy
C) copy
D) reverse_copy
A) copy_reverse
B) inverse_copy
C) copy
D) reverse_copy
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
41
The algorithms reverse, reverse_copy, rotate, and rotate_copy are contained in the header file ____.
A) utility
B) structures
C) algorithm
D) operations
A) utility
B) structures
C) algorithm
D) operations
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
42
The algorithm ____ counts the occurrences of a given value in a given range.
A) count
B) reverse
C) index
D) rotate
A) count
B) reverse
C) index
D) rotate
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
43
The algorithm ____ is used to determine the largest element in a given range.
A) min_element
B) max_element
C) count
D) top_element
A) min_element
B) max_element
C) count
D) top_element
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
44
The algorithm ____ is used to randomly order the elements in a given range.
A) reorder_shuffle
B) shuffle
C) order_shuffle
D) random_shuffle
A) reorder_shuffle
B) shuffle
C) order_shuffle
D) random_shuffle
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
45
The algorithm ____ is used to access and process each element in a given range by applying a function, which is passed as a parameter.
A) with_each
B) do_each
C) for_each
D) for
A) with_each
B) do_each
C) for_each
D) for
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
46
The algorithm ____ determines whether the elements in one range appear in another range.
A) includes
B) contains
C) has
D) associates
A) includes
B) contains
C) has
D) associates
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
47
The algorithm ____ is used to find the elements that are contained in two ranges of elements.
A) find_union
B) union
C) set_union
D) has_union
A) find_union
B) union
C) set_union
D) has_union
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
48
The algorithm ____ is used to find the elements in one range of elements that do not appear in another range of elements.
A) set_union
B) set_difference
C) set_join
D) set_innerjoin
A) set_union
B) set_difference
C) set_join
D) set_innerjoin
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
49
In the second form of ____, the binary operation op is applied to the elements in the range.
A) adjacent_find
B) adjacent_connect
C) adjacent_member
D) adjacent_difference
A) adjacent_find
B) adjacent_connect
C) adjacent_member
D) adjacent_difference
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
50
The algorithm ____ is used to manipulate the elements of two ranges.
A) inner_product
B) outer_product
C) inner_join
D) cross_product
A) inner_product
B) outer_product
C) inner_join
D) cross_product
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck