Questions

Q:

What will be output of following c code?

void main()
{
struct bitfield
{
unsigned a:5;
unsigned c:5;
unsigned b:6;

}bit;
char *p;
struct bitfield *ptr,bit1={1,3,3};
p=&bit1;
p++;
clrscr();
printf("%d",*p);
getch();
}

Answer

Output: 12

Explanation:
Binary value of a=1 is 00001 (in 5 bit)
Binary value of b=3 is 00011 (in 5 bit)
Binary value of c=3 is 000011 (in 6 bit)

In memory it is represented as:
Let address of bit1 is 500 which initialize to char pointer p. Since can is one byte data type so p++ will be 501. *p means content of memory location 501 which is (00001100) and its binary equivalent is 12. Hence output is 12.

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

0 3145
Q:

The Indian to beat the computers in mathematical wizardry is

A) Shakuntala Devi B) Raja Ramanna
C) Rina Panigrahi D) Ramanujam
 
Answer & Explanation Answer: A) Shakuntala Devi

Explanation:
Report Error

View Answer Report Error Discuss

3 3143
Q:

Who amongst  the following authors was in 2007 conferred the knighthood by the British government?

A) Salman Rushdie B) V.S. Naipaul
C) Chetan Bhagat D) Khushwant Singh
 
Answer & Explanation Answer: A) Salman Rushdie

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: General Awareness
Exam Prep: Bank Exams
Job Role: Bank PO

1 3143
Q:

Which State has been declared as the Open Defecation Free state?

A) Uttarakhand B) Arunachal Pradesh
C) Maharashtra D) Uttar Pradesh
 
Answer & Explanation Answer: B) Arunachal Pradesh

Explanation:

Arunachal Pradesh State has been declared as the Open Defecation Free state.

Report Error

View Answer Report Error Discuss

Filed Under: General Awareness
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Bank PO

6 3142
Q:

Who is the author of the book A Journey ?

A) Tony Blair B) Bikram seth
C) Janardhan takur D) harisen
 
Answer & Explanation Answer: A) Tony Blair

Explanation:

Author of the book A journey  is Tony Blair

Report Error

View Answer Report Error Discuss

Filed Under: Books and Authors

1 3142
Q:

An important tool for project scope management is

A) Fast tracking B) Work breakdown structure
C) Crashing D) A Gantt Chart
 
Answer & Explanation Answer: B) Work breakdown structure

Explanation:

Work breakdown structure is an important tool for project scope management.

 

Project Scope Management refers to the set of processes that ensure a project’s scope is accurately defined and mapped. Scope Management techniques enable project managers and supervisors to allocate just the right amount of work necessary to successfully complete a project—concerned primarily with controlling what is and what is not part of the project’s scope.

Report Error

View Answer Report Error Discuss

6 3142
Q:

Water which is suitable for drinking is called _______________ water.

 

A) hygienic B) sparkling
C) potable D) sanitary
 
Answer & Explanation Answer: C) potable

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Chemistry
Exam Prep: Bank Exams

0 3140
Q:

Who is author of the book 'Preparing for the Twenty First Century '

A) V.S.Naipaul B) John Ruskin
C) Paul Kennedy D) Henry Kissinger
 
Answer & Explanation Answer: C) Paul Kennedy

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Books and Authors

1 3139