Win a copy of JDBC Workbook this week in the JDBC and Relational Databases forum
or A Day in Code in the A Day in Code forum!

Adam Czysciak

Ranch Hand
+ Follow
since Feb 25, 2005
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Adam Czysciak

Thanks for all the cows folks The good news to all the other participants is that one of you still has the chance to get this free ticket Unfortunatelly I won't be able to attend GeeCON @Prague (I already miss that mug ), so one of you will be the lucky one. Enjoy!
Well, this moose art is a compiled version of sample class doing all the calculations (in fact this class is a contest solution itself). I took .class file, gzipped it and Base64-encoded. So the main code first decodes and decompresses the String to get byte[] representation of .class file. Then I create inner anonymous class extending ClassLoader to be able to defineClass() - so that jvm is aware of my Class called '$'. Last step is creating an instance and calling the method '$' plus casting the result to desired Map.

some tricks used:
$: java identifier for byte[] array
__ = '7' >> 8: __ is an identifier for total class length, the initialization expression is simply 0, it is incremented when reading decompressed stream chunks
1<<('0'>>2) means 1 << (48 / 4) = 1<< 12 = 4096 bytes allocated

$0x7F - ordinary Java identifier starting with $, could be "is" as well
$.length>>0b1111 when calling defineClass means 4096 >> 15 = 0 (look at defineClass signature, this is starting offset)

The .class file is a compiled version of this code:

This "hidden" class could have been retrieved by decompiling the byte[] representation (althought I'm not sure if there are any jdk8 compatible decompilers yet).
and the second one, dedicated to all the ranchers out there :-)

OK, my two cents. The first one:

ah, okay I just thought that every solution posted here should be compileable when pasted into wordOccurrence method *without* any other changes in the class source. So, to be clear, you can test it by pasting code and doing auto-organize imports in your favourite IDE, and then launching Or we can put our imports (from JDK8 only) in the solution.
Tim, your solution doesn't comply The Rules As far as I understood, the whole solution should fit inside wordOccurrence method. You have helper methods. Not to mention required additional imports.
Tim, which TimeZone should we fit to meet the end-of-Friday criteria ?

Originally posted by Narendra Dhande:

I have account accesible from But when I try to login to it is giving error. I try to create new account it ask for candidate ID, Registaration number and test date. What is candidate ID and registration number.


'sun_assignment' is not the same as 'sun' page - there are different logins.

- Candidate ID is your Prometric ID (eg "SR123456")
- Registration number is the confirmation number - you can take it from your exam registration confirmation email you got after registering for the exam

What others can help is to prepare to SCEA part 1. And this was really covered a few months ago, when people took part 1. Browse this forum and you'll find the answers. Shortly - you need to know mostly about EJB3, including JPA, WebServices and JSF.

If you're asking about my preparation - I only read core j2ee design patterns, to systematize my knowledge.

For part II/III - this is something you can't prepare for. You need to have experience in this field. Of course when talking about the subject itself, not the way you present it (because you can learn UML, if you don't know it yet).

passed too, but no email received yet. Fortunatelly, certmanager is the most important here

Originally posted by James Jurach:
Oops. I hadn't noticed until just now that the trial version of Sparx Enterprise Architect displays a watermark, "EA 7.0 Unregistered Trial Version" all across and down each image I export. Either I need to be ok with turning in something so ugly, or certification is now more expensive than I had hoped.

They won't decrease your scores because of this, I believe
I tried IBM Rational Software Architect, but resigned after 1 day of testing :-) Right now I'm testing Sparx Systems Enterprise Architect, seems to be quite cool.
Guys, why do you talk about the assignment here? Do you really want this forum to be closed till Dec 12th?