AceTheInterview
Jobs in Pune | Work better in teams | Socialize with friends | Submit Q&A | Tell a friend
Search site for 

Top 100 Interview Questions & Answers in a convenient and easy to read book!

“I bought this guide a few days ago to prepare for my interview with Oracle. Many of the questions they asked me were from this guide. I found this book absolutely great!”

– Ravi, California

Read more comments...

Interview Questions And Answers RSS Feed

Answers »

  1. Submitted By: MATHEW — September 26, 2007
    +7 votes
      + -

    chicken is a function which takes argument as grain type and returns egg.

    egg chicken(grain x);

  2. Submitted By: Edwin — October 1, 2007
    +8 votes
      + -

    chicken is a class which has some attributes:
    - no of eggs: int
    - hair color: enum
    And also has some methods:
    public Sound cocks()
    public walk()
    public eat()
    etc

  3. Submitted By: Cristian — October 24, 2007
    +4 votes
      + -

    class Road { /* … */ };
    class Bridge { /* … */ };

    template
    class Chicken
    {
    public:
    static void do_cross() { };
    };

    template
    class Chicken
    {
    // prevent chicken at compile-time from crossing the f…ing road
    };

  4. Submitted By: vasu — December 13, 2007
    -4 votes
      + -

    Very intelligent and technically sound answer given.Even a person with no knowledge of programming can also understand whats a function actually does?

  5. Submitted By: James — December 18, 2007
    +0 votes
      + -

    A keyboard is placed in front of the cage. Every time a key is pecked a seed will eject. Initially, code will not compile.

    However, if an infinite number of chickens peck away at the keyboards for an infinite amount of time, it is theorized that eventually the random pecking will produce an algorithm to finally prove which came first….

  6. Submitted By: slj — January 19, 2008
    +2 votes
      + -

    class Chicken: public Bird
    {
    public:
    char* LatinName() { return “Gallus gallus”; }
    char* Name()
    {
    Language lang = GetUserLanguage();
    return Translation(LatinName(),lang);
    }
    bool isDomesticated () { return true; }
    int Population (int year)
    {
    int pop = AnimalPopulationDatabase.Querey(LatinName(),year);
    if (pop==0) pop = 24000000000;
    return pop;
    }
    int MaxLifeSpan() { return 11; }
    int MinLifeSpan() { return 4; };
    int ActualLife ()
    {
    if (isRasiedForEgg())
    {
    return 2.5;
    }
    else // for meat
    {
    if (IsCaged()) return 0.5;
    else return 1.2;
    }
    }

    }

  7. Submitted By: Molly — March 13, 2008
    +0 votes
      + -

    class Chicken:public Bird
    {
    float weight,height,age;
    enum color=(LIGHTYELLOW,DARKYELLOW,ORANGE,DEEPORANGE);
    Bird parent;
    bool gender;

    public:
    Chicken(float w=5.0,float h=0.5,float a=1.0,Bird p,bool g)
    {
    weight=w;
    height=h;
    age=a;
    parent=p;
    gender=g;
    }

    //ALL GETS AND SETS
    //functions like
    //LayEggs,Walk,Talk,Eat,Sleep,NCalls…
    //Most of them virtual in Bird class

  8. Submitted By: silly — March 24, 2008
    not yet rated
      + -

    ::chicken is a function which takes argument as grain type and returns egg.

    ::egg chicken(grain x);

    I beg to differ…..

    Chicken is a function which takes an argument as grain type and returns chicken shyt.

  9. Submitted By: J1gs4w — June 2, 2008
    not yet rated
      + -

    typedef unsigned int uint;
    class chicken:public bird
    {
    bool sex;
    uint age;
    uint no_eggs;
    state_t state;
    public:
    bird(bool sx=MALE, uint ag=0, uint no_eggs=0, state_t st=F_CKING);
    bool shit();
    bool crossTheRoad();
    uint getEggs();
    bool f_ck();
    void eat();
    void die();
    bool sleep();
    ~bird();
    };

  10. Submitted By: J1gs4w — June 2, 2008
    not yet rated
      + -

    OR
    class chicken:public ________
    {
    int _;
    bool __;
    float ___;
    public:
    chicken():_(8),__(0),___(8);
    int ____(){ in##t i_n_t_=’__’; }
    bool _____(); {bool b_o_o_l=(bo##ol)(’:)’)}
    float _______();{float f_l_o_a_t=(flo##at)(’;)’)}
    };

    Simple, isn’t it?

  11. Leave an Answer/Comment

    To prove you're a person (not a spam script), type the security text shown in the picture. Click here to regenerate some new text.
    Click to hear an audio file of the anti-spam word

Our Sponsors
Our Sponsors
Contact Us | FAQ | Sitemap | Terms of Use | Privacy Policy | Tell a Friend

Copyright © 1999-2006 Jeeve Technologies LLC. All rights reserved.