Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Overload operators??
Message
From
06/02/2002 01:01:33
 
General information
Forum:
ASP.NET
Category:
Other
Miscellaneous
Thread ID:
00615854
Message ID:
00615881
Views:
21
>>I'm trying to learn C#, I just bought a book and am going through it. I'm also only experienced in FoxPro and although it may be 'overload operators' may pertain to FoxPro, I've personally never heard of it.
>>
>>So, what does overload operators mean?
>>
>
>If you create a custom type, you may want to add two variables of those types one to other. You can "overload" the "+" operator in the way it can perform the operation on your custom type.
>
>For example, assume that the "+" operator can perform additions only on numeric types. You create a new type who consist of a number and a char (ie. 2H or 6L) and call this type numchar. If you try to add two numchar, you will have an error because the operation was unknown for this type. You can overload the "+" operator to perform additions on the numchar type.
>
>I dont know if my explaination was clear enough, may be a real "english speaker" can jump in and help you more... :)
>
>HTH

Thanks, I think I'm getting it.
Previous
Reply
Map
View

Click here to load this message in the networking platform