M Davis

Greenhorn
+ Follow
since Nov 09, 2010
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
1
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by M Davis

Madangopal Venkatesan wrote:Hey guys,

Just got thru my OCPJWCD certification with a whopping 100%!

Books and other stuff that helped me...
1. HDFS
2. General API lookups
3. Enthuware -> The tests here are brilliant, really!

Last but the most important - Passion for Servlets and JSPs!

Like Muhammed Ali says,
“Champions aren´t made in the gyms. Champions are made from something they have deep inside them - a desire, a dream, a vision.”



Good job! Congrats Madangopal !!
12 years ago

Dennis Deems wrote:http://download.oracle.com/javase/6/docs/api/

You'll see the Index option at the top of the page. It's an alphabetical index to the API.



Thanks Dennis!

Ajith Kallambella wrote:Oh yes!...there are a zillion more classes which override equals() method. Just go to Java API Documentation, switch to Index view and look for equals(Object).
I am sure you will not have to remember all of these for the SCJP exam.
Ajith



This will probably seem like a dumb question but...

What is the Java API Doc Index view and how do you switch to it?
Yes, I did miss that. Thank you so much for your response. I appreciate it.

Here's the short mini-program that I am using to test this...


Hey guys,

I did a search and could not find any information on this and it's sort of bugging me. I'm having trouble moving on because I feel like I am missing something.

It concerns the Regex extraction of file names beginning with "proj1" from the text string.

The string looks like this: ..."proj3.txt,proj1sched.pdf,proj1,proj2,proj1.java"... in the book.

The Regex expression in the book is; proj1([^,])*

The results are supposed to be:

10 proj1sched.pdf
25 proj1
37 proj1.java


For some reason when I try this all I get are the numbers without the actual file names. My results look like this: 10 25 37 without the file names.

Could somebody suggest what may be wrong here? I've read through a couple of times and I must be missing something. Could the book be incorrect here?

Thank you for any attention you can give this.

Mark
Thanks a bunch Bhaarat. That was what I thought. I sometimes overthink these things and wanted to clariy.

Thank you also ankur. You cleared some things up for me also.

That really helps clear up a lot. Just to clarify something...

If the code actually read this way;


We would get a TRUE and a FALSE test then. How would that work out then for the if statement? It's not the & operator so both don't have to be true.

Would the if statement then be TRUE and the "x" be appended to s?
Hello,

Hopefully I am asking this in the correct place. This is in relation to question 8 of Chapter 4 in the Sierra/Bates SCJP book.

there is an if statement that reads;

Boolean b2 = false;
"if((b2 = false) | (21%5) > 2) s += "x";

The question answers say that s never gets the "x" appended. I'm having trouble understanding how this actually works.
b2 is false so that renders TRUE on the left side of the "|". But but the test of 21%5 >2 renders FALSE.

So the way I read this since it is not a || being used here is that one is true so the test should be true. The logical operator is | and not an &.
What am I failing to understand about the Non Short-Circuit operator. I'm not able to figure out what is really happening here.

Thanks for any help you can provide.

Chandika Gunawardhana wrote:

Deepak Bala wrote:Well thats weird. As long as you have the printed score sheet, you should have no trouble.

Write to Oracle again and ask them what happened



I have the score sheet received from the Prometric center after passing the exam. I'll write to Oracle again. thanks.



Chandika, were you able to get this resolved?