0

How would you solve the part of the C# Intermediate code project that requires operator overloading?

So I've managed to solve this without operator overloading... But how do you solve it with operator overloading? I don't understand the syntax of operator overloading.

26th Feb 2025, 6:46 AM
MattMad
MattMad - avatar
5 Réponses
+ 4
Maybe you can share the task, and also add your code (as per the following instruction), where you attempt what you know from overloading, and someone can help you with what isn't working. https://sololearn.com/compiler-playground/Wek0V1MyIR2r/?ref=app
26th Feb 2025, 7:25 AM
Ausgrindtube
Ausgrindtube - avatar
26th Feb 2025, 3:45 PM
Ausgrindtube
Ausgrindtube - avatar
0
My solution. (It works, but I didn't do what I'm supposed to do.) https://sololearn.com/compiler-playground/cUlyABKPFJ5m/?ref=app
26th Feb 2025, 12:24 PM
MattMad
MattMad - avatar
0
Managed to solve that one and was referring to something else
26th Feb 2025, 5:22 PM
MattMad
MattMad - avatar
0
MattMad your code is different from the one in my Android course, but maybe something like this: https://sololearn.com/compiler-playground/cJgqb2a2PeVz/?ref=app
26th Feb 2025, 5:34 PM
Bob_Li
Bob_Li - avatar