ST Microelectronics Placement: Sample Questions 10 - 11 of 40

Get unlimited access to the best preparation resource for competitive exams : get questions, notes, tests, video lectures and more- for all subjects of your exam.

Question 10

Question

MCQ▾

CA in CSMA/CA stands for

Choices

Choice (4)

a.

Collision avoidance

b.

Collision approval

c.

Critical access

d.

Question does not provide sufficient data or is vague

Answer

a.

Explanation

CSMA/CA (Carrier Sense Multiple Access/Collision Avoidance) is a protocol for carrier transmission in 802.11 networks. It operates on Data Link Layer. CSMA/CD (Carrier Sense Multiple Access/Collision Detection) deals with transmission after a collision has occurred in the network. CSMA/CA acts before to prevent collision. As it is said prevention is better than cure, CSMA/CA is also better than CSMA/CD.

Question 11

Question

MCQ▾

Which one is the declaration of the static string?

Choices

Choice (4)

a.

Char string [30]

b.

Static string

c.

‘static string’

d.

“static string”

Answer

b.

Explanation

If we want the variable to get defined as static, we need to add static keyword before its name. Its default initial value is always 0. If any variable is defined as static then value of that variable persists between different function calls.

Like,

  1. main ()
  2. {
  3.     staticinti;
  4.     for (i =0; i<4; i++ )
  5.     {
  6.         printf (“%d”, i);
  7.     }
  8. }

will print 0123

Developed by: