OOP: Method overloading

  • 8
  • Locked
Let's display matrices in different ways, however we want. OOP gives us a wonderful tool for this: method overloading. Overload the printMatrix method in 8 different ways. You should end up with 10 different printMatrix methods.
You can't complete this task, because you're not signed in.
Comments (2)
  • Popular
  • New
  • Old
You must be signed in to leave a comment
30 June 2021, 09:57
Change the printMatrix value type, e.g. printMatrix(int m, int n, Integer value), change print statement and then call it in the same way as previous printMatrix method with String value! Do it again x7 times one for double, float, long, boolean, short, character, byte....Enjoy!!!
senthamil selvan
Level 20 , Eral, India
21 February 2019, 10:42
i get ans but not verify