Website developers have become some of the most looked out people in the world today. Whether a developer or a user, it is important to know how to gauge a good website. The quiz below tests on several website concepts.
A. a URL that stores the session ID
B. a cookie that stores the session ID
C. a cookie that stores the session data
D. a cookie that stores the session ID and the session data
Rate this question:
A. is a regular array
B. is an associative array
C. is an object
D. is a cookie
Rate this question:
A. get the name of the session cookie
B. get the session ID
C. generate a new session ID
D. get the data for a session ID
Rate this question:
A. a random value between 0 and 1
B. a value of either 0 or 1
C. a value of either “heads” or “tails”
D. a reference to the $coin variable
Rate this question:
A. $_ARGUMENTS variable
B. $_FUNCTION variable
C. func_get_args function
D. func_num_args function
Rate this question:
A. can change the original variable without using a return statement
B. can change the variable and pass it back by using a return statement
C. can’t change the variable
D. must make a copy of the variable before it changes it
Rate this question:
A. namespaces create logical function groups
B. all the functions for an application have to be stored in the same file
C. all functions have global scope
D. most programmers use the same naming conventions for functions
Rate this question:
Use namespaces
B. Use libraries
C. Store function files in lower-level directories
D. Use include paths
Rate this question:
A. private methods to set and get their values
B. public methods to set and get their values
C. a constructor to set and get their values
D. a destructor to set and get their values
Rate this question:
A. classes
B. objects
C. properties
D. result sets
Rate this question:
A. override the inherited properties
B. override the inherited methods
C. delete any of the inheritied properties
D. delete any of the inherited methods
Rate this question:
A. public function Cart($arg1, $arg2) {
B. public function __construct($arg1, $arg2) {
C. private function Cart($arg1, $arg2) {
D. private function __construct($arg1, $arg2) {
Rate this question:
A. new Cart($arg1, $arg2)
B. new Cart(arg1, arg2)
C. Cart_constructor($arg1, $arg2)
D. Cart_constructor(arg1, arg2)
Rate this question:
A. match_preg
B. preg_match
C. search_preg
D. preg_search
Rate this question:
True
1
C. A count of the number of matches
A count of the number of matches and an array that contains all of the matches
Rate this question:
If a match is found when the preg_split function is executed, it returns
B. An array of all of the matches
C. An array of the substrings that are created by removing the matches
D. A count of the number of matches and an array of substrings
Rate this question:
A. completely validate all types of user entries
B. only to check whether user entries have the right format
C. completely validate some types of user entries
D. are limited to the validation of string data
Rate this question:
A. message property of the exception object
B. getMessage method of the exception object
C. message property of the exception class
D. getMessage property of the exception class
Rate this question:
A. a runtime error occurs in a try block
B. a runtime error is caught by a catch block
C. PHP encounters invalid data
D. a runtime error occurs
Rate this question:
A. /[d5]/
B. /+\d[5]?/
C. /^\d{5}$/
D. /$\d5^/
Rate this question:
A. You can use the count function to return the number of elements in the array.
B. You can use both integer and string indexes with an associative array.
C. You can use a foreach loop to access the values of an associative array but not the indexes
D. You can delete elements from an associative array.
Rate this question:
A. add a new element with an index that’s beyond the next one that’s available
B. store an empty value in an array
C. delete or unset an element from an array
D. store a NULL value in an array
Rate this question:
A. Use the array_values function to remove all gaps and re-index the array.
B. Use a foreach loop to process the array, which skips elements that contain nulls.
C. Use a for loop that contains extra code that skips elements that contain nulls.
D. Use the array_fill function to replace all gaps in the array with empty strings.
Rate this question:
A. array_shift
B. array_unshift
C. array_push
D. array_pop
Rate this question:
A. a for loop
B. a foreach loop
C. the array_sum function
D. the sum_array function
Rate this question:
A. Both indexes in an array of arrays must be integer indexes
B. An associative array can’t be used as an array within another array.
C. All of the arrays within an array must have the same number of elements.
D. You can use both for loops and foreach loops to work with an array of arrays.
Rate this question:
A. 141.95|312.95|411|10.95|
B. 141.95|212.95|312.95|10.95|
C. 141.95|212.95|411|312.95|
D. 10.95|
Rate this question:
Quiz Review Timeline (Updated): Sep 7, 2023 +
Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.
Wait!
Here's an interesting quiz for you.