C - Elements of C Language Questions and Answers

Take Exam

The Elements of C Language questions with answers cover the fundamental building blocks of C programming, including variables, data types, operators, and control structures. These programming questions and answers are ideal for beginners aiming to strengthen their coding foundation. Each question is designed to test conceptual clarity and coding accuracy, commonly seen in TCS, Wipro, and Infosys placement exams. With explanations and examples, these MCQs help learners prepare effectively for both academic tests and real-world programming challenges.

C - Elements of C Language

Showing 10 of 58 questions

41.  Identify the  correct statement .

  • The variable names VOLUME and volume are identical
  • The variable names Sum andsum are identical.
  • Variables are not declared before use.
  • Variable names may be absent in a declaration.
Show Answer Report

42. Identify the invalid identifier.

  • NET_$
  • BINGO
  • _ACCOUNT
  • _4
Show Answer Report

43.  Which is the most appropriate variable initialization ?

  • # define MAX 100
  • int x, y; y = 15
  • float y = 2.14;
  • char c;c = 'O' ;
Show Answer Report

44.  Tokens are separated by using 

  • :
  • .
  • ;
  • separator
Show Answer Report

45.  An escape sequencce commences with 

  • \
  • /
  • ?
  • #
Show Answer Report

46.  Identify the worng declaration. 

  • int n = {7}
  • char c2 = 'A' + 25, cl = 'Z';
  • int x ; y ;
  • int x = 10, y = x * 20, year;
Show Answer Report

47.  Identify the wrong sentence. 

  • # define isa preprocessor facility.
  • # define aids in modifying a constant value throughout the program.
  • # define uses a statement terminator.
  • # define improves the readabilitty of the program.
Show Answer Report

48.  What is avariable declaration ?

  • The assignment of propertiesto a variable.
  • Theassignment of memory space to a variable.
  • The assignment of properties and memory space to a variable.
  • The assignment of properties and indentification to a variable.
Show Answer Report

49.  What are strings ?

  • They are contiguous blocks of characters and a terminating NUL.
  • They are individual characters linked together to form a string.
  • Both options (a) and (b)
  • None of the above.
Show Answer Report

50.  In addition to the length of the string, whatmust be considered while determining the minimum number of characters required to store a C strings ?

  • An EOF at the end must be considered.
  • A '\0' at the end must be considered.
  • Apart from the string itself, there is nothing else tobe considered when determining the length of the string.
  • A '\0\n' at the end must be considered.
Show Answer Report
Questions and Answers for Competitive Exams Various Entrance Test