New ! Computer Applications MCQ Practise Tests



12th Standard English Medium Computer Applications Subject PHP Conditional Statements Book Back 1 Mark Questions with Solution Part - II

12th Standard

    Reg.No. :
  •  
  •  
  •  
  •  
  •  
  •  

Computer Applications

Time : 01:00:00 Hrs
Total Marks : 5

    1 Marks

    5 x 1 = 5
  1. Statement which is used to make choice between two options and only option is to be performed is written as

    (a)

    if statement

    (b)

    if else statement

    (c)

    then else statement

    (d)

    else one statement

  2. What will be the output of the following PHP code ?
    < ?php
    \($\)a = “”;
    if (\($\)a)
    print “all”;
    else
    print “some”;
    ? >

    (a)

    all

    (b)

    some

    (c)

    error

    (d)

    no output

  3. What will be the output of the following PHP code ?
    < ?php
    \($\)x = 10;
    \($\)y = 20;
    if (\($\)x > \($\)y + \($\)y != 3)
    print “hi” ;
    else
    print “how are u”;
    ? >

    (a)

    how are u

    (b)

    hi

    (c)

    error

    (d)

    no output

  4. What will be the output of the following PHP code ?
    < ?php
    \($\)x = 10;
    \($\)y = 20;
    if (\($\)x > \($\)y && 1||1)
    print “hi” ;
    else
    print “how are u”;
    ? >

    (a)

    how are u

    (b)

    hi

    (c)

    error

    (d)

    no output

  5. What will be the output of the following PHP code ?
    < ?php
    if (-100)
    print “hi” ;
    else
    print “how are u”;
    ? >

    (a)

    how are u

    (b)

    hi

    (c)

    error

    (d)

    no output

*****************************************

Reviews & Comments about 12th Standard English Medium Computer Applications Subject PHP Conditional Statements Book Back 1 Mark Questions with Solution Part - II updated Book back Questions

Write your Comment