Questions

Q:

We want to round off x, a Float to an Int value. The correct way to do so would be

A) Y = ( int ) ( x + 0.5 ) ; B) Y = int ( x + 0.5) ;
C) Y = ( int ) x + 0.5; D) Y = ( int ) ( ( int ) x + 0.5 )
 
Answer & Explanation Answer: A) Y = ( int ) ( x + 0.5 ) ;

Explanation:

Rounding off a value means replacing it by a nearest value that is approximately equal or smaller or greater to the given number.

 

y = (int)(x + 0.5); here x is any float value. To roundoff, we have to typecast the value of x by using (int)

 

Example:

 

#include

 

int main ()

 

{

 

  float x = 2.6;

 

  int y = (int)(x + 0.5);

 

  printf ("Result = %d\n", y );

 

  return 0;

 

}

 

Result : 3

Report Error

View Answer Report Error Discuss

Filed Under: Programming

3 6489
Q:

Which of the following is an example of a simile?

A) Clouds of vanilla cotton candy floated in the sky. B) His stomach rumbled like an approaching train.
C) She was drowning in a sea of grief. D) He was a hurricane in her heart.
 
Answer & Explanation Answer: B) His stomach rumbled like an approaching train.

Explanation:

In the given options, "His stomach rumbled like an approaching train" is an example of Simile.

All the other options are examples of metaphors. 

 

Simile and Metaphor are both figure of speeches in English which are used for comparing things but the only difference is Simile uses LIKE or AS words in comparing and metaphor directly compares without using any words.

Report Error

View Answer Report Error Discuss

Filed Under: English
Exam Prep: AIEEE , Bank Exams , CAT , GATE , GRE , TOEFL
Job Role: Analyst , Bank Clerk , Bank PO , Database Administration , IT Trainer

4 6485
Q:

Which one do you need for tennis

A) A helmet B) A racket
C) Flippers D) A basket
 
Answer & Explanation Answer: B) A racket

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Sports

12 6483
Q:

Purushmedha i.e. Male sacrifies is referred to in

A) krishna Yajurveda B) Shukla Yajurveda
C) Shatapatha Brahman D) panchvisha Brahman
 
Answer & Explanation Answer: C) Shatapatha Brahman

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Indian History

2 6480
Q:

Water soluble vitamin include

A) vitamin C B) niacin
C) riboflavin D) all of the above
 
Answer & Explanation Answer: D) all of the above

Explanation:
Report Error

View Answer Report Error Discuss

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

31 6480
Q:

Which keystroke is used for updating a field?

A) F11 B) F12
C) F6 D) F9
 
Answer & Explanation Answer: D) F9

Explanation:

F9 keystroke is used for updating a field.

Report Error

View Answer Report Error Discuss

5 6478
Q:

Who is the first Indian to take a hat trick in an international test ?

A) Jasu Patel B) Kapil Dev
C) Harbajan Singh D) B. S. Chandra Sekhar
 
Answer & Explanation Answer: C) Harbajan Singh

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Sports
Exam Prep: Bank Exams , CAT
Job Role: Bank Clerk , Bank PO

13 6478
Q:

Srikakulam was the capital of 

A) Sakas B) Pahlavas
C) Andhras D) Ashoka
 
Answer & Explanation Answer: C) Andhras

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Indian History

9 6474