C Programming :: Basic Concepts

Home > C Programming > Basic Concepts > General Questions

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

51 / 87

 Originally 'C' was developed as:

ASystem programming language

BGeneral purpose language

CData processing language

DNone of above

Answer: Option C

Explanation:

Here is no explanation for this answer

Workspace

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

52 / 87

 Latency time is:

ATime taken by read/write head mechanism to position itself over appropriate cylinder

BTime taken to transfer a dta from memory

CTime taken by appropriate sector to come under read/write head

DNone of above

Answer: Option D

Explanation:

Here is no explanation for this answer

Workspace

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

53 / 87

 The two types of file structure existing in VSAM file are

AKey sequenced structure, entry sequenced structure

BKey sequence structure, exit sequenced structure

CEntry sequence structure, exit sequenced structure

DNone of above

Answer: Option C

Explanation:

Here is no explanation for this answer

Workspace

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

54 / 87

 In C language, a hexadecimal number is represented by writing

Ax

Bx0

C0x

Dh

Answer: Option B

Explanation:

Hexadecimal numbers in C are represented by 0x or 0X.

For example: the value in Hexadecimal can be written as 0x64, which is equivalent to 100 in decimal.

Hence, the correct option is C.

Workspace

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

55 / 87

 In which of the cases, the content inside if statement will not execute

Aif(-100)

Bif(0)

Cif (23.45)

DAll of the above

Answer: Option A

Explanation:

Option A and C will execute as both -100 and 23.45 are not equal to 0, so the test condition becomes True, hence the contect inside if statement will execute.

Whereas, option B will not execute as 0 not equal to 0 is False, so the content inside if statement won't execute.

Therefore, correct option is B 

Workspace

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

56 / 87

 In an absolute loading scheme, which loader function is accomplished by assembler

AReallocation

BAllocation

CLinking

DBoth (a) and (b)

Answer: Option D

Explanation:

Here is no explanation for this answer

Workspace

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

57 / 87

 What is the sizeof(long int)

A4 bytes

B2 bytes

CCompiler dependent

D8 bytes

Answer: Option C

Explanation:

The size for long int depends on the compiler. For a 32-bit model, the size is 4 bytes, whereas for a 64-bit model the size is 8 bytes

Hence, the correct option is C.

Workspace

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

58 / 87

 main()
{
int a;
printf("%d",scanf(%d,&a));
}
What will be the output of the above program.

A0

B1

CAs per Input

DNone of the above

Answer: Option A

Explanation:

Incorrect answer



Answer is : 1



scanf returns the number of inputs scanned

Workspace

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

59 / 87

 In the command scanf, h is used for

AShort int

Bint

Cshort unit

DNone of these

Answer: Option A

Explanation:

Here is no explanation for this answer

Workspace

NA
SHSTTON
0
Solv. Corr.
0
Solv. In. Corr.
0
Attempted
0 M:0 S
Avg. Time

60 / 87

 What is the precedence order from high to low ,of the symbols ( ) ++ /

A( ) ,/, ++

B( ) , ++, /

C/,( ) , ++

DNone of these

Answer: Option B

Explanation:

Option B is correct. () has the highest priority, then comes ++, followed by /.

For more clarity about the precedence and associativity of various operators used in C, you can refer the table below-

CategoryOperatorAssociativity
Postfix() [] -> . ++ - -Left to right
Unary+ - ! ~ ++ - - (type)* & sizeofRight to left
Multiplicative* / %Left to right
Additive+ -Left to right
Shift<< >>Left to right
Relational< <= > >=Left to right
Equality== !=Left to right
Bitwise AND&Left to right
Bitwise XOR^Left to right
Bitwise OR|Left to right
Logical AND&&Left to right
Logical OR||Left to right
Conditional?:Right to left
Assignment= += -= *= /= %=>>= <<= &= ^= |=Right to left
Comma,Left to right

Workspace