1 2 3 4 5 6 7 8 9 10 |
def add(instanceOf, * args): if instanceOf = = < int >: result = 0 if instanceOf = = < str >: result = <>! for i in args: result = result + 1 return result print (< int >, 3 , 4 , 5 ) print (< str >,<i>,<live>,< in >) |
am new to python currently learning oop chapter so try this code to run but it's giving me error in <int> second line.