I\'m creating a class which is supposed to be able to be used with an array of any type of number (float, int, etc), so here is one method I have:
// T exten
In Java, the arithmetic operators will only work on primitive types. The problem here is that Java has class representations of these primitive types, and the switch from one to another is generally implicit, via the feature known as autoboxing.
In this case you will need to implement methods for the types of arithmetic operations you need, possibly having to create overloaded methods for every possible numeric type passed in for every operation.