Home » PHP » PHP Introduction » Question
  1. Which of the following PHP statements will output Hello interview Mania on the screen?
    1. sprintf (“Hello interview Mania ”);
    2. echo (“Hello interview Mania ”);
    3. print (“Hello interview Mania ”);
    4. printf (“Hello interview Mania ”);
    5. B, C and D
Correct Option: E

echo(), print() and printf() all three can be used to output a statement onto the screen. The sprintf() statement is functionally identical to printf() except that the output is assigned to a string rather than rendered to the browser.



Your comments will be displayed only after manual approval.