In Java I was able to make method overloading inside a class like the following (pseudocode):
public class Test
private double result;
Test(){result=0;}
public double func(int a, int b, int c)
{
result=a+b+c;
}
public double func(int a, int b)
{
result=a*b;
}
public double func(int a)
{
result=Math.pow(a,2);
}
How can I get the same behaviour in Python? I know that I can use default values, but I got a problem when I want to implement different operations in a method.
Any help?