I have a rather simple problem, but I can't solve it somehow.
class lokomotiva extends element{ public lokomotiva(double maxMasa){ super(maxMasa); this.maxMasa = maxMasa; } }
when i try to compile the whole thing (this is just a part of the code), I get an error:
possible loss of precision
found :double
required: int
at: this.maxMasa = maxMasa
maxMasa is a double number, and I want it to be, but how to assign it to an object?
Any help would be appriciated