New ! Computer Applications MCQ Practise Tests

12th Standard Computer Applications Looping Structure English Medium Free Online Test One Mark Questions with Answer Key 2020 - 2021

12th Standard

    Reg.No. :
  •  
  •  
  •  
  •  
  •  
  •  

Computer Applications

Time : 00:10:00 Hrs
Total Marks : 10

    Answer all the questions

    10 x 1 = 10
  1. Loops that iterate for fixed number of times is called

    (a)

    Unbounded loops

    (b)

    Bounded loops

    (c)

    While loops

    (d)

    For loops

  2. What will be displayed in a browser
    when the following PHP code is
    executed:
    < ?php
    for (\($\)counter = 20; \($\)counter < 10;
    \($\)counter++){
    echo “Welcome to Tamilnadu “;
    }
    echo “Counter is: $counter”;
    ? >

    (a)

    Welcome to Tamilnadu

    (b)

    Counter is: 20

    (c)

    Welcome to Tamilnadu Counter is: 22

    (d)

    Infinite loop

  3. PHP supports which types of looping techniques;

    (a)

    for loop

    (b)

    while loop

    (c)

    foreach loop

    (d)

    all the above

  4. Consider the following code
    < ? php
    \($\)count=12;
    do{
    printf(“%d squared=%d
    ”,
    \($\)count, pow(\($\)count,2));
    } while(\\($\)count<4);
    ? >
    What will be the output of the code

    (a)

    12 squared 141

    (b)

    12 squared=141

    (c)

    “12 squared=141”

    (d)

    Execution error

  5. What will be the output of the
    following PHP code ?
    < ?php
    for (\($\)x = 1; \($\)x < 10;++\($\)x)
    {
    print “*\t”;
    }
    ? >

    (a)

    **********

    (b)

    *********

    (c)

    ***********

    (d)

    Infinite loop

  6. What will be the output of the
    following PHP code ?
    < ?php
    for (\($\)x = -1; \($\)x < 10;--\($\)x)
    {
    print \($\)x;
    }
    ? >

    (a)

    123456713910412

    (b)

    123456713910

    (c)

    1234567139104

    (d)

    Infinite loop

  7. Which of the following is an exit check loop?

    (a)

    foreach

    (b)

    for

    (c)

    while

    (d)

    do..while

  8. Which of the following is an entry check loop?

    (a)

    foreach

    (b)

    for

    (c)

    while

    (d)

    do..while

  9. ________ loops execute a block of code a specified number of times.

    (a)

    foreach

    (b)

    for

    (c)

    while

    (d)

    do..while

  10. What will be displayed in a browser when the following PHP code is executed:
    < ?php
    for ($i=1;$i<=5; $i++)
    {
    echo "$i";
    }
    ? >

    (a)

    12345

    (b)

    1234

    (c)

    123

    (d)

    None of the above

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

TN 12th Standard Computer Applications free Online practice tests

Reviews & Comments about 12th Standard Computer Applications Looping Structure English Medium Free Online Test One Mark Questions with Answer Key 2020 - 2021

Write your Comment