Questions

Q:

What would be the output of the following program?

main()

{

    extern int fun ( float );

    int a;

    a = fun ( 3. 14 );

    printf ("%d", a);

}

int fun ( aa )

float aa ;

{

     return ( (int) aa );

}

Answer

Error occurs because we have mixed the ANSI prototype with K & R style of function definition.


When we use ANSI prototype for a function and pass a float to the function it is promoted to a double. When the function accepts this double into a float a type mismatch occurs hence the error.


The remedy for this error could be to define the function as :


int fun (float aa)


{


  ....


}

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

9 8935
Q:

The cross section of a chisel is usually

A) Octagonal B) Rectangular
C) Hexagonal D) Circular
 
Answer & Explanation Answer: A) Octagonal

Explanation:

The cross section of a chisel is usually octagonal.

103313_xl1545906956.jpg image

Report Error

View Answer Report Error Discuss

Filed Under: General Science
Exam Prep: AIEEE , Bank Exams
Job Role: Analyst , Bank Clerk

3 8930
Q:

When combining with nonmetallic atoms, metallic atoms generally will

A) Lose electrons and forms cations B) Gain electrons and forms anions
C) Lose electrons and forms anions D) Gain electrons and forms cations
 
Answer & Explanation Answer: A) Lose electrons and forms cations

Explanation:

When combining with nonmetallic atoms, metallic atoms generally will Lose electrons and forms cations.

 

As the ionization energy of te metals are very low, so they can easily lose electrons and form positively charged ion called cations.

Report Error

View Answer Report Error Discuss

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

3 8926
Q:

How do you go about familiarizing yourself with the products you sell?

Answer

Retail products often change seasonally.  Can you quickly update yourself on all the new information so you can be prepared to sell the new inventory to customers as soon as it lands on the shelf


 

Report Error

View answer Workspace Report Error Discuss

Subject: Retail

11 8920
Q:

Among the following States, which one was formed last

A) Andhra Pradesh B) Gujarat
C) Karnataka D) Punjab
 
Answer & Explanation Answer: A) Andhra Pradesh

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Indian Politics

12 8918
Q:

Which one of the following liberty is not embodied in the Preamble to the Constitution of India?

A) Liberty of Thought B) Liberty of Expression
C) Liberty of Belief D) Economic Liberty
 
Answer & Explanation Answer: D) Economic Liberty

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Indian Politics

9 8915
Q:

Whose period was known as the Golden Age of Rome?

Answer

 Augustus Caesar

Report Error

View answer Workspace Report Error Discuss

Subject: World History

21 8914
Q:

Riddle

How can you add eight 8's to get the number 1,000? (only use addition)

Answer

The key to this math riddle is realizing that the one place must be zero.
888 +88 +8 +8 +8 =1,000

Report Error

View answer Workspace Report Error Discuss

Subject: Math Puzzles

26 8914