TCS Papers: Sample Questions 386 - 388 of 502

Examrace Placement Series prepares you for the toughest placement exams to top companies.

Question number: 386

» Basic CS » Networks

Short Answer Question▾

Write in Short

How can you turn-on and turn-off CAS?


  • Code Access Security Tool (Caspol. exe) can be used to turn security on and off.

  • caspol -security off turns off security

  • caspol -security on turns on security

  • In the. NET Framework 4.0, for using Caspol. exe < LegacyCasPolicy > element must be set to true.

Question number: 387

» Languages » C & C Plus Plus

Short Answer Question▾

Write in Short

What is wrong in the statement? scanf (“%d”, whatnumber);


  • An ampersand “&” symbol must be placed before the variable name whatnumber.

  • Placing & means whatever integer value is entered by the user is stored at the “address” of the variable name.

  • This is a common mistake for programmers, often leading to logical errors.

The image define the scanf() function

The Image Define the Scanf () Function

Given the image define the scanf () function

Question number: 388

» Languages » C & C Plus Plus

Essay Question▾

Describe in Detail

When is the “void” keyword used in a function?


  • Function declarations could return a value or not.

  • If a function does not return a value then “void” is placed at the leftmost part of the function header.

  • When a return value is expected after the function execution, the data type of the return value is placed instead of “void”.

  • “void” keyword in return specifies that the function does not return a value.

  • In function parameter list “void” specifies that function takes no parameters.

  • In the declaration of a pointer void specifies that the pointer is “universal”.