Question: 1-Create multidimensional array as on the picture. Remove section echo and replace it with two for loops dislaying exactly the same message as original code.

1-Create multidimensional array as on the picture. Remove "section echo" and replace it with two "for loops" dislaying exactly the same message as original code. Consider using if, elseif, else conditions in order to add elements of the sentence such as: ": In stock: " , ", sold: " etc.

Your code goes here:

2-Take only an array from previous point and transform it into associative array with scheme: "Brand"=>"Volvo","Stock"=>22,"Sold"=>18

Encode it into JSON and display.

Your code goes here:

3-

Underline correct answers:

Whom would you compare REST-API to:

a cook

a waiter

a consumer

Finish the sentence: REpresentational State Transfer (REST) is an architectural style that defines a set of constraints to be used for creating web services. REST API is a way of accessing web services

in a simple and flexible way with processing.

in a simple and flexible way with main process.

in a simple and flexible way without processing.

All communication done via REST API uses only HTTP request.

True

False

Which sentence is true?

A request is sent from client to server in the form of web URL as HTTP GET or POST or PUT or PURGE request.

A request is sent from client to server in the form of web URL as HTTP GET or POST or PUT or DELETE request.

A request is sent from client to server in the form of web URL as HTTP GET or POST request only.

What does mysqli_query return?

an object

an array

a table

What should be in $response in a given code:

json_encode($response)

a table

an array

an object

an array of objects

What values will given code display?

$x = 127;

do {

echo "$x ";

$x+=16;

} while ($x < 153);

?>

143

127, 143

127, 143, 152

Which of given codes will display every-twenty value?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!