I've been asked by my tutor to find a way of getting an Integer
of Max value in java without using the actual word Integer
, along with Float
, Double
and the numbers 0-9. He also encouraged us to use the web to find answers.
I would rather not post the code but all it really is is a comment stating the above, some class and method code and an assert line checking that i==Integer.MAX_VALUE
.
Ive spent a few days working on this and ive come to the conclusion that I need to somehow use a Long to make a value that will wrap around to Integer.MAX_VALUE
when converted to an int
, I just can't figure out the actual code to do this.
Any help would be nice.