Skip to content

Latest commit

 

History

History

1-Getting-Started

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Solutions of CHAPTER 1: GETTING STARTED

[A]

REASON:- A character constant is a constant which uses single quotation around characters.

Invalid:- '3.15' eLearning' 'Quest'

REASON:- No Comma/Space in integer constant & No exponentiation operator available.

Invalid:- "35,550" "2^3" "4 6 5 2"

[B]

REASON:- No special symbol except underscore allowed in variable naming

   B'day $hello  #HASH _main() total% %name% stack-queue	

REASON:- Keyword cannot be used as a variable.

	int

REASON:- Variable name should start with an alphabet.

	Same as 1st

[C]

(a) True

(b) True

(c) True

(d) True

(e) True

(f) True

(g) True

(h) True

(i) True

(j) False

(k) True

(l) False

[D]

(a) Escape Sequence 

(b) Real Constant

(c) Integer Constant

(d) Character Constant

(e) Exponential Form

(f) Function

(g) Format Specifier

(h) Statement Terminator

(i) Literal

(j) Identifier

(k) Address of Operator

(l) Output Function

(m) Input Function

[E]

(a) Statement Terminator is missing, and it couldn't be figured out whether the expression is (a+b)*(b-35)

   or a+(b*b)-35 because of unavailability of parentheses.

(b) Nesting of comments is not allowed.

(c) "&" Operator is Missing.

(d) Statement terminator operator ";" is missing in integer declaration and scanf & printf functions.