ballislifeqw6483 ballislifeqw6483
  • 07-08-2019
  • Computers and Technology
contestada

Determine the exact output of the code:

$num = 3.14;

echo floor($num);

Select one:

a. 3.75

b. 3.5

c. 4

d. 3

Respuesta :

PhantomWisdom PhantomWisdom
  • 12-08-2019

Answer:

3

Explanation:

The function floor() is used to give the integer which is smaller than or equal to the provided decimal value.

for example:

let a=5.8

floor(a);

the function provides the value 5 (smaller than or equal to 5.8).

In the given code:

variable num assigns the number 3.14.

then, floor(3.14) gives the value 3 (smaller than or equal to 3.14).

then, the echo print the value on the screen.

Therefore, the correct answer is 3.

Answer Link

Otras preguntas

£11000 of 3.9% compound interest of 3 years ?
1. Explain how you think two brown rabbits could have white offspring. 2. Predict the coat color of offspring produced by two white rabbits.
Why did Mussolini believe that a fascist government would help him achieve his goals
c. What is important about the progressive dates on the map?
Was the birthday present something he really wanted
Explain why Americans distrust the idea of political parties?
Investment of $100 at 15% simple interest for 15 years
HURRY!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Think about a girl on a swing. When is the kinetic
what times what equals 29
why did early modern humans develop spoken language?