This content has been marked as final. Show 21 replies
...That doesn't tell me much. You need to be specific; I'm no mindreader.
... arent working properly after the update
The method I posted was just a (slightly) better version of yours. I didn't look at the rest of your code.
You can't stuff an int into my (or your) method and expect to get the hexadeciaml representation of that decimal number. You'll first have to do some calculations of course.
For example: if you have the decimal value of 2744, you first do:
No you have the values 10, 11, and 8. Use those three values on your (or my) conversion method, and you'll ens up with the characters 'A', 'B' and '8'.
2744 = 16 * 171, rest value: 8 171 = 16 * 10 , rest value: 11 10 = 16 * 0 , rest value: 10
Be carefull not to add the characters to each other!
// wrong! System.out.println('A'+'B'+'8'); // ok String s = ""+'A'+'B'+'8'; System.out.println(s);
Sorry about that promo I really do appreciate yourNo need to apologise; no harm done.
and I have just realised that the problemGood you figured it out.
was in the CharacterStack itself as I had it set up
to accept integers only :-( bah lol
Thank you again and I really do appreciate your helpNo problem, and you're welcome.