Click here to Skip to main content
15,881,424 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
if we have two functions like

int fun1(int,int)
double fun1(int,int)

this is ex of what overloading or overidding?
Posted
Comments
Sergey Alexandrovich Kryukov 18-Jan-13 1:53am    
Who told you so?!
—SA
dan!sh 18-Jan-13 1:59am    
Tooth fairy. :)
Sergey Alexandrovich Kryukov 18-Jan-13 2:01am    
:-)
Anyway, I finally answered this bad question. Maybe just lost my time (please see my other comments...).
—SA
dan!sh 18-Jan-13 1:58am    
What?
dan!sh 18-Jan-13 1:59am    
This is an example of you being too lazy to read a book or browse one of the >billion online tutorials.

1 solution

It is absolutely impossible to answer without the context of this code. Moreover, this question makes no sense at all.
And this is a very poor method of learning something. It's much better to read a simple manual, do the exercises, and ask question only when you stuck.

Overriding is a serious effect, the very base and the heart of OOP. It's too long story to explain how OOP works, but you will need to learn it.

Overloading is just the confusing term for... practically nothing. Nothing is "overloaded" because nothing is "loaded". This is a jargon for a very simple situation: two or more totally different functions may have identical name, if and because a compiler can distinguish them by different signature. For certain call codes, it may or may not be possible; if not, a compilation error is shown.

—SA
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900