Questions

Q:

Answer the following Program

#define CHARSIZE 8

#define MASK(y) (1 << y % CHARSIZE)

#define BITSLOT (y) (y / CHARSIZE)

#define SET(x,y) ( x[BITSLOT(y)] = MASK(y) )

#define TEST(x,y) ( x[BITSLOT(y)] & MASK(y) )

#define NUMSLOTS(n) ((n + CHARSIZE - 1) / CHARSIZE)

 

Give the above macros how would you

1. declare an array arr of 50 bits

2. put the 20th bit on

3. test whether the 40th bit is on or off

Answer

1. char arr[NUMSLOTS(50)];


2. SET (arr, 20);


3. if (TEST (arr, 40))

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

0 2886
Q:

Which of the following is a polymer?

A) Glycerol B) Amino acid
C) Nucleic acid D) Fatty acid
 
Answer & Explanation Answer: C) Nucleic acid

Explanation:

Nucleic acid is a polymer among the given options.

Report Error

View Answer Report Error Discuss

Filed Under: Chemistry
Exam Prep: AIEEE , Bank Exams , GATE
Job Role: Analyst , Bank Clerk , Bank PO

1 2885
Q:

Steel tycoo Laksmi Mittal has acquired minority stakes in which Indian financial service company?

A) Anand Rathi Financial Services B) Indiabulls Credit Services
C) Farallon Capital D) Kothari Pioneer
 
Answer & Explanation Answer: B) Indiabulls Credit Services

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Business Awareness

8 2884
Q:

The constitution of India describes India as

A) Unitary B) A quasi - federal
C) Union of States D) A Federation
 
Answer & Explanation Answer: C) Union of States

Explanation:

The Article - I of the constitution of India describes India as Union of States.

Report Error

View Answer Report Error Discuss

Filed Under: Indian Politics
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Analyst , Bank Clerk , Bank PO

4 2884
Q:

Speed regulation of synchronous motor is

A) 1% B) 25%
C) Zero D) 0.5%
 
Answer & Explanation Answer: C) Zero

Explanation:

speed_regulation_of_synchronous_motor1553077296.jpg image

Synchronous motor is a motor which runs at a constant speed irrespective of load attached to it. So the speed regulation of synchronous motor is ZERO.

Report Error

View Answer Report Error Discuss

Filed Under: Physics
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Analyst , Bank Clerk , Bank PO

5 2883
Q:

Which of the following is a feature of leptin?

A) It acts primarily on the brain B) It is secreted by the brain and acts on fat cells
C) It is an enzyme D) It is usually deficient in thin people
 
Answer & Explanation Answer: B) It is secreted by the brain and acts on fat cells

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Biology
Exam Prep: AIEEE , Bank Exams , CAT , GATE
Job Role: Analyst , Bank Clerk , Bank PO

1 2883
Q:

In the following question, a sentence has been given in Direct/Indirect speech. Out of the four alternatives suggested, select the one which best express
the same sentence in Indirect/Direct speech.


The holy prophet said, " God helps those who help others."

A) The holy prophet said that God helped those who helped others. B) The holy prophet said that God helps those who help others.
C) The holy prophet said that God helps people who help others. D) The holy prophet said that God helps those people who help others.
 
Answer & Explanation Answer: B) The holy prophet said that God helps those who help others.

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: English
Exam Prep: AIEEE , Bank Exams , CAT

2 2883
Q:

The National forest policy aims at maintaining how much of the geographical area under forests

A) Half B) One-third
C) One-fourth D) One-fifth
 
Answer & Explanation Answer: B) One-third

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Indian Economy

0 2882