473,399 Members | 3,106 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

real life example

plzz give me the answer of these question

1 Give exmples of virtual func and pure virtual func in real world
2 Give example of function overloading in real world
3 Write the structure of switch statement.
thanx

Jun 14 '06 #1
14 5976
dost wrote:
plzz give me the answer of these question

1 Give exmples of virtual func and pure virtual func in real world
2 Give example of function overloading in real world
3 Write the structure of switch statement.


These are not questions.
Jun 14 '06 #2
dost wrote:
plzz give me the answer of these question

1 Give exmples of virtual func and pure virtual func in real world
2 Give example of function overloading in real world
3 Write the structure of switch statement.
thanx


Plzz do your own homework:

http://parashift.com/c++-faq-lite/ho...t.html#faq-5.2

If you can't figure it out, I'm sure Google can help.

Cheers! --M

Jun 14 '06 #3

dost wrote:
plzz give me the answer of these question

1 Give exmples of virtual func and pure virtual func in real world
virtual int main() { return new int(0); }

pure virtual int main() { return virtual int(0); }
2 Give example of function overloading in real world
void function(int x) { cout << x; }

....
int y, b, q; char * x;

// overloading function call
function(y, b, q, x);
3 Write the structure of switch statement.
switch(test) {
case 1, 2, 34:
doX();
continue;
case 4, 5, 6:
doY();
continue;
case else:
doDefaultAction();
}
thanx


No problem. Make sure your friends get copies too.

Jun 14 '06 #4
Noah Roberts wrote:
dost wrote:
plzz give me the answer of these question

1 Give exmples of virtual func and pure virtual func in real world


virtual int main() { return new int(0); }

pure virtual int main() { return virtual int(0); }
2 Give example of function overloading in real world


void function(int x) { cout << x; }

...
int y, b, q; char * x;

// overloading function call
function(y, b, q, x);
3 Write the structure of switch statement.


switch(test) {
case 1, 2, 34:
doX();
continue;
case 4, 5, 6:
doY();
continue;
case else:
doDefaultAction();
}
thanx


No problem. Make sure your friends get copies too.


Laughing my *ss off.
Jun 14 '06 #5
actually this question may be stupid but it was asked me in
interview.........they do not need code....but the example......
thank you
red floyd wrote:
Noah Roberts wrote:
dost wrote:
plzz give me the answer of these question

1 Give exmples of virtual func and pure virtual func in real world


virtual int main() { return new int(0); }

pure virtual int main() { return virtual int(0); }
2 Give example of function overloading in real world


void function(int x) { cout << x; }

...
int y, b, q; char * x;

// overloading function call
function(y, b, q, x);
3 Write the structure of switch statement.


switch(test) {
case 1, 2, 34:
doX();
continue;
case 4, 5, 6:
doY();
continue;
case else:
doDefaultAction();
}
thanx


No problem. Make sure your friends get copies too.


Laughing my *ss off.


Jun 15 '06 #6
dost wrote:
actually this question may be stupid but it was asked me in
interview.........they do not need code....but the example......


Those questions are well below the minimum questions required to interview a
C++ candidate. Of course some interviewers can just start with such
questions, to prime the pump, but if you need to ask us about them then you
should consider learning more programming before trying to get a job doing
it.

Oh, and redfloyd was laughing because Noah was trying to get you in
trouble...

--
Phlip
http://c2.com/cgi/wiki?ZeekLand <-- NOT a blog!!!
Jun 15 '06 #7
dost wrote:
actually this question may be stupid but it was asked me in
interview.........they do not need code....but the example......


Please don't top-post. Putting your reply inline and/or below the post
you are responding to is customary here.

As for your interview questions, see this FAQ (particularly the
sentence after "shame on you"):

http://www.parashift.com/c++-faq-lit....html#faq-6.14

Cheers! --M

Jun 15 '06 #8

Phlip wrote:
Oh, and redfloyd was laughing because Noah was trying to get you in
trouble...


Don't listen to these guys. Those answers are correct and sure to
generate an optimum score on the assignment. These guys are just
trying to throw you off because it is normally bad form to answer
homework assignments here. You seemed like you had tried to do it on
your own enough to warrant actual answers instead of smart ass remarks.
Apparently these guys disagree.

Jun 15 '06 #9
Noah Roberts wrote:
Don't listen to these guys. Those answers are correct and sure to
generate an optimum score on the assignment. These guys are just
trying to throw you off because it is normally bad form to answer
homework assignments here. You seemed like you had tried to do it on
your own enough to warrant actual answers instead of smart ass remarks.
Apparently these guys disagree.


It was a job interview, not an assignment, so your trap still won't work.

Nice try, though - and I'm sure we'll see it again some day... ;-)

--
Phlip
http://c2.com/cgi/wiki?ZeekLand <-- NOT a blog!!!
Jun 15 '06 #10
Phlip wrote:
Noah Roberts wrote:
Don't listen to these guys. Those answers are correct and sure to
generate an optimum score on the assignment. These guys are just
trying to throw you off because it is normally bad form to answer
homework assignments here. You seemed like you had tried to do it on
your own enough to warrant actual answers instead of smart ass remarks.
Apparently these guys disagree.


It was a job interview, not an assignment, so your trap still won't work.

Nice try, though - and I'm sure we'll see it again some day... ;-)


And if he came here looking for answers, I suspect he won't be employed
as a c++ programmer anytime soon.
Jun 15 '06 #11

Sgt. York wrote:
Phlip wrote:
Noah Roberts wrote:
Don't listen to these guys. Those answers are correct and sure to
generate an optimum score on the assignment. These guys are just
trying to throw you off because it is normally bad form to answer
homework assignments here. You seemed like you had tried to do it on
your own enough to warrant actual answers instead of smart ass remarks.
Apparently these guys disagree.


It was a job interview, not an assignment, so your trap still won't work.

Nice try, though - and I'm sure we'll see it again some day... ;-)


And if he came here looking for answers, I suspect he won't be employed
as a c++ programmer anytime soon.


I don't know...I make an ass of myself all over the Internet all the
time and nobody has called me on it. Maybe searching usenet is a
dieing art...using it seems to be...

Jun 15 '06 #12
Noah Roberts wrote:
Sgt. York wrote:
Phlip wrote:
Noah Roberts wrote:

Don't listen to these guys. Those answers are correct and sure to
generate an optimum score on the assignment. These guys are just
trying to throw you off because it is normally bad form to answer
homework assignments here. You seemed like you had tried to do it on
your own enough to warrant actual answers instead of smart ass remarks.
Apparently these guys disagree.
It was a job interview, not an assignment, so your trap still won't work.

Nice try, though - and I'm sure we'll see it again some day... ;-)

And if he came here looking for answers, I suspect he won't be employed
as a c++ programmer anytime soon.


I don't know...I make an ass of myself all over the Internet all the
time and nobody has called me on it. Maybe searching usenet is a
dieing art...using it seems to be...


Yeah, that sounded a bit like I was slamming the great talent that
frequents this newsgroup. I really meant to say he should know the
answers to those silly questions in his sleep before attempting
employment in the field.
Jun 15 '06 #13
I dont need ur suggestion regarding my rivision....if u dont want to
answer just...do not reply....
and thanx 2 Noah Roberts

Sgt. York wrote:
Noah Roberts wrote:
Sgt. York wrote:
Phlip wrote:
Noah Roberts wrote:

> Don't listen to these guys. Those answers are correct and sure to
> generate an optimum score on the assignment. These guys are just
> trying to throw you off because it is normally bad form to answer
> homework assignments here. You seemed like you had tried to do it on
> your own enough to warrant actual answers instead of smart ass remarks.
> Apparently these guys disagree.
It was a job interview, not an assignment, so your trap still won't work.

Nice try, though - and I'm sure we'll see it again some day... ;-)

And if he came here looking for answers, I suspect he won't be employed
as a c++ programmer anytime soon.


I don't know...I make an ass of myself all over the Internet all the
time and nobody has called me on it. Maybe searching usenet is a
dieing art...using it seems to be...


Yeah, that sounded a bit like I was slamming the great talent that
frequents this newsgroup. I really meant to say he should know the
answers to those silly questions in his sleep before attempting
employment in the field.


Jun 15 '06 #14
dost wrote:
I dont need ur suggestion regarding my rivision....if u dont want to
answer just...do not reply....
and thanx 2 Noah Roberts


Dude, Noah did not answer your question. He wrote a bunch of lies to trick
you, so stop thanking him!

And don't write chat-style in forums that need more clarity, like this one.

--
Phlip
Jun 15 '06 #15

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

26
by: Steven Bethard | last post by:
I thought it might be useful to put the recent lambda threads into perspective a bit. I was wondering what lambda gets used for in "real" code, so I grepped my Python Lib directory. Here are some...
6
by: Paul | last post by:
In real life situation, do we ever come across a situation where we would need two base objects in an object. A snippet is worth 1000 words (: so... class Base { }; class Derived1:public Base...
4
by: WittyGuy | last post by:
Hi all, Though I know the concepts of both abstract class & virtual function (like derived class pointer pointing to base class...then calling the function with the pointer...), what is the real...
3
by: Gérard Talbot | last post by:
Hello all, When webfonts are used for purely cosmetic/ornemental reasons and on a large scale, I don't agree. When webfonts are used because Unicode support among browsers for a particular...
5
by: VMI | last post by:
I understand the principle behind generics, but I'm not sure how I can apply them to a real-life situation. Anybody have an example that shows how someone can benefit from a generic class? The...
67
by: bluejack | last post by:
A recent post asking for help with unions reminded me of this component of the C language that I have only used a couple of times, and those almost entirely out of personal whim -- Unions for the...
5
by: playagain | last post by:
Please help me to build a list of examples of stack and queue in real life situation... Conditions: The object concerned must only one object. And the object must be tangible. Example: Queue...
3
by: Mark Shroyer | last post by:
I guess this sort of falls under the "shameless plug" category, but here it is: Recently I used a custom metaclass in a Python program I've been working on, and I ended up doing a sort of write-up...
2
by: Pramod | last post by:
Where can i get sample real life examples on C#? for example... on topics like exception handling, reflection, delegates, functions, iterators etc etc. Let me know the link if possible. Thanks...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.