Questions

Q:

What would be the output of the following program?

main()

{

   struct emp

   {

        char *n;

        int age;

   };

   struct emp e1 = { "Dravid", 23};

   struct emp e2 = e1;

   strupr (e2.n);

   printf ("\n%s",e1.n);

}

Answer

DRAVID


When a structure is assigned, passed, or returned, the copying is done monolithically. This means that the copies of any pointer fields will point to the same place as the original. In other words, anything pointed to is not copied. Hence, on changing the name through e2.n it automatically changed e1.n

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

0 2680
Q:

The agricultural revolution led to the need for organized

A) greenhouse gas reform B) government
C) pest control D) technological reform
 
Answer & Explanation Answer: B) government

Explanation:

The Agricultural Revolution led to the need for more organized civilizations and societies i,e government.

The_agricultural_revolution_led_to_the_need_for_organized1556260336.jpg image

 

The Agricultural Revolution was a period of technological improvement and increased crop productivity that occurred during the 18th and early 19th centuries in Europe.

Report Error

View Answer Report Error Discuss

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

0 2680
Q:

Graphically, the market demand curve is

A) greater than the sum of the individual demand curves B) the horizontal sum of individual demand curves
C) steeper than any individual demand curve that is part of it D) the vertical sum of individual demand curves
 
Answer & Explanation Answer: B) the horizontal sum of individual demand curves

Explanation:
Report Error

View Answer Report Error Discuss

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

0 2680
Q:

Which sport man is branded as "Fast Man on Earth"?

A) Milka Singh B) Usain Bolt
C) Ronaldo D) Christian
 
Answer & Explanation Answer: B) Usain Bolt

Explanation:

Usain Bolt is branded as "Fast Man on Earth".

Report Error

View Answer Report Error Discuss

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

0 2679
Q:

Write a c program for binary search.

Answer

#include<stdio.h>
int main(){

    int a[10],i,n,m,c=0,l,u,mid;

    printf("Enter the size of an array: ");
    scanf("%d",&n);

    printf("Enter the elements in ascending order: ");
    for(i=0;i<n;i++){
         scanf("%d",&a[i]);
    }

    printf("Enter the number to be search: ");
    scanf("%d",&m);

    l=0,u=n-1;
    while(l<=u){
         mid=(l+u)/2;
         if(m==a[mid]){
             c=1;
             break;
         }
         else if(m<a[mid]){
             u=mid-1;
         }
         else
             l=mid+1;
    }
    if(c==0)
         printf("The number is not found.");
    else
         printf("The number is found.");

    return 0;
}

Sample output:
Enter the size of an array: 5
Enter the elements in ascending order: 4 7 8 11 21
Enter the number to be search: 11
The number is found.

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

0 2679
Q:

The fastest century record in one day cricket hold by

A) Chris Gayle B) A B Devilliers
C) Rohit Sharma D) Shahid Afridi
 
Answer & Explanation Answer: B) A B Devilliers

Explanation:

The fastest century record in one day International cricket was hold by South Africa Batsman A.B.Divilliers against West Indies on Jan 18, 2015 in Johannesburg. It was 100 in 31 balls.

Report Error

View Answer Report Error Discuss

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

15 2678
Q:

Which statement describes nuclear binding energy?

A) It is the energy that is required to overcome mass defect. B) It is the result of converting mass to energy.
C) It is the energy that is required to bind protons and neutrons together in a nucleus. D) None of the above
 
Answer & Explanation Answer: A) It is the energy that is required to overcome mass defect.

Explanation:

Nuclear binding energy is the minimum energy that would be required to disassemble the nucleus of an atom into its component parts. These component parts are neutrons and protons, which are collectively called nucleons.

Report Error

View Answer Report Error Discuss

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

0 2678
Q:

Which of the following statements is not true about metabolism?

A) Younger people generally have a slower metabolism than adults. B) Basal metabolism is the amount of energy needed for sustaining life.
C) Basal metabolism is measured by the amount of calories burned when your body is inactive. D) Metabolism is influenced by numerous factors, such as heredity and age.
 
Answer & Explanation Answer: A) Younger people generally have a slower metabolism than adults.

Explanation:

Metabolism is the set of life-sustaining chemical transformations within the cells of organisms. The three main purposes of metabolism are the conversion of food/fuel to energy to run cellular processes, the conversion of food/fuel to building blocks for proteins, lipids, nucleic acids, and some carbohydrates, and the elimination of nitrogenous wastes.

 

Younger people have faster metabolism than adults. Hence, the given statement 'Younger people generally have a slower metabolism than adults' is FALSE.

 

Report Error

View Answer Report Error Discuss

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

1 2677