Technical Questions

Q:

What would be the output of the following program?

main()

{

    char a[] = "Visual C++";

    char *b = "Visual C++";

    printf ("\n%d %d", sizeof (a), sizeof (b));

    printf ("\n%d %d", sizeof (*a), sizeof (*b));

Answer

11  2


 1   1

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

1 1773
Q:

Which Stack is used in 8085?

Answer

LIFO (Last In First Out) stack is used in 8085. In this type of Stack the last stord information can be retrieved first

Report Error

View answer Workspace Report Error Discuss

Subject: Hardware

0 1771
Q:

What's the speed and device maximum specs for Firewire?

Answer

IEEE 1394 (Firewire) supports the maximum of 63 connected devices with speeds upto 400 Mbps.

Report Error

View answer Workspace Report Error Discuss

Subject: Hardware

0 1768
Q:

What would be the output of the following program?

main()

{

    int i = -3, j =2, k =0, m ;

    m = ++j && ++i || ++k ;

    Printf ( "\n%d%d%d%d", i , j , k , m );

}

Answer

-2  3  0  1

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

1 1767
Q:

What would be the output of the following program, if the array beigns at address 65486?

main()

{

    int arr[] = {12,14,15,23,45};

    printf ("%u %u", arr, &arr);

}

Answer

65486  65486

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

0 1759
Q:

How would you find the length of each string in the following Program?

main()

{

    char *str[] = { "Frogs", "Do", "Not" , "Die" , "They" , "Croak!"};

    printf ("%d%d", sizeof (str), sizeof (str[0]));

}

Answer

main()


{


   char *str[] = { "Frogs", "Do", "Not", "Die." , "They", "Croak!" };


   int i;


         for ( i = 0;i<=5;i++)


         printf ("\n%s%d", str[i], strlen( str[i]));


}

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

1 1752
Q:

Which error are you likely to get when you run the following program?

main()

{

  struct emp

  {

      char name[20];

      float sal;

  };

  struct emp e[10];

  int i;

  for ( i = 0 ; i <= 9; i++)

        scanf ( "%s %f" , e[i].name, &e[i].sal );

}

Answer

Floating point formats not linked

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

0 1749
Q:

What would be the output of the following program?

main()

{

    float a = 0.7;

    if ( a < 0.7f )

          printf ( " C ");

    else 

          Printf ( " C++ ");

}

Answer

C++

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

0 1744