ST Microelectronics Papers: Sample Questions 12 - 13 of 40

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

Question number: 12

» Aptitude

Short Answer Question▾

Write in Short

What will be the output of the given C program?

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


  • Here, variable i is defined as character variable. A character variable is by default a signed character. It has range from -128 to + 127. If we want to define any character be unsigned then we need to add unsigned keyword before declaring it. Unsigned character has range from 0 to 255.
  • Here, as i is a signed character it cannot take value bigger than + 127. Hence when value of i is + 127 and we perform i++ it becomes -128 instead of + 128. -128 is less than 255, hence the condition is still satisfied. Here onward i would take values like -127, -126, -125, …, +126, +127, -128, -127, …etc.
  • Thus this is an indefinite loop.

Question number: 13

» Aptitude



CA in CSMA/CA stands for


Choice (4) Response


Critical access


Collision approval


Collision avoidance


None of the above




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.