Search Header Logo

PHP TEST -6

Authored by Arivuselvi A

Computers

University

PHP TEST -6
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

5 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the below symbols is a newline character?

\r

\n

/n

/r

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of following variables can be assigned a value to it?

(i) $3hello

(ii) $_hello

(iii) $this

(iv) $This

All of the mentioned

Only (ii)

(ii), (iii) and (iv)

(ii) and (iv)

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

If $a = 12 what will be returned when ($a == 12) ? 5 : 1 is executed?

12

1

Error

5

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following PHP statements will output Hello World on the screen?

(i) echo ("Hello World);

(ii) print ("Hello World);

(iii) printf ("Hello World);

(iv) sprintf ("Hello World);

(i) and (ii)

(i), (ii) and (iii)

All of the mentioned

(i), (ii) and (iv)

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following PHP code?

< ?php $score = 1234;

$scoreboard = (array) $score;

echo $scoreboard[0];

?>

1

Error

1234

2

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?

Discover more resources for Computers