Eric Zanders

Greenhorn
+ Follow
since Sep 15, 2004
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
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Eric Zanders

Dear Pradip,
don't mean to be rude but according to my (Belgian) calendar that be September 21st..........
[ August 16, 2006: Message edited by: Eric Zanders ]
Thx Ramesh!
After taking a short look at the links (or at least at the pages they refer to ) I'm sure there is a future for AJAX.

Greetz
Eric
Hi,
I recently heared something buzzing about AJAX.
Can anybody please explain, in a nutshell, how I can implement or make use of it in my current and next developments? What are the real advantages (for the users as well as for me)?

Thx 4 D feedback.

Greetz
Eric
Dear Seema,

does the examinator already cover JAVA 5?
As I am only active with JAVA for about a year now, would it take me long to get prepared with your examinator?

Thx for your reply.
Eric
Hi there,

I'm kind of new (less than 1 year taking courses and being 'productive') to OO and JAVA and what they call a (very) late starter: I'm nearing the 40's and thought that JAVA-programming would be a cool new turningpoint in my job curriculum...
As I'm so 'fresh' in the whole concept of OO and JAVA I was wondering if your book would be helpfull to fill-in the remaining blind spots?
Also there are people asking me if I can be persuaded to taking on JAVA-tests so that they see that their investments do pay up.
Would your book be a good guideline in, let's say, getting me through the JAVA(5)-exams?

Thanks for your reply.

Eric
17 years ago
Found it!!!

In a nutshell: you refer a1 to an A with value "A1" and an otherA with value "A2". Same goes for a2 (A2 & A3) and a3(A3 & A1).
In the for-loop you ask of a0 to refer to the otherA value of the A it is referring to, thus creating a loop. If you increase the maxvalue of i in the for-statement (ie to 9), you'll see A1A2A3A1A2A3A1A2A3A1A2A3, the last A1A2A3-cycle always being created by finalize() (due to the garbage collection).

Am I right? It may be that I still mix-up terminologies, for that I apologize. (This is only my 7� week of Java...)
[ October 27, 2004: Message edited by: Eric Zanders ]
Thanks Barry, it now results in answer d...
[ October 27, 2004: Message edited by: Eric Zanders ]
What I always try is to compile and see the result myself.
I then insert 'printing'messages to try and trace the path that is being followed. However, in this case after compiling succesfully and trying to run it, I got this errormessage:
Exception in thread "main" java.lang.NoSuchMethodError: main

Anyone got a clue?
Fendel,
being a beginner aswell, I'll try to explain how I get to 3 objects:

Originally posted by Fendel Coulptz:


then how many string objects are created in this example? i don't understand why 3 objects are created.

String s1,s2,s3,s4;
s1 = "Hello";
s2 = s1;
s3 = s2 + "Pal";
s4 = s3;



1� object is "Hello" which is referenced by s1 and s2.
2� object is "Pal"
and the 3� object is the concatenation of "Hello" (referenced by s2) and "Pal", thus resulting in "HelloPal" being referenced by s3 and s4.

About the a1==a2 case, I believe there is a typo in


String a2 = "alibaba and forty theives";



If I'm wrong, please do forgive AND correct me.

More @ this link The SCJP Tip Line
[ October 27, 2004: Message edited by: Eric Zanders ]
18 years ago
Anders,

To convert an ASCII(int) to its corresponding char:

where i is an int with a value between 33 & 126 (resulting in an upper- or lowercase letter or a number)

The other way 'round:

where a is a char, being upper- or lowercase or a number.

Hoping to have been of any assistance.
Eric
18 years ago
The actual question is: who's dealin' and which cardgame is this anyway?
That's because you're missing a piece, Mani.
It works fine with me...
Thanks Paul.
So returning to the initial question, the result (number of String objects) then should be 6?
18 years ago
Dear Paul,

As I'm only a beginner I tend to make mistakes. (which is normal, I guess...)

Would it have been more correct if I had stated that the content of the object s1 was modified?

Anyway, thanks for correcting me. How else am I going to learn from my mistakes?

Greetz

J
18 years ago
Rohan,

I would say 5:
1� s1.
2� s2.
3� The string concatenation is not stored in s1 but it exists.
4� Same case for the s2 string concatenation.
5� The string you'll print is the concatenation s1, a blank and s2.

To verify this I created a little testprogram:

When you run this, you'll notice that:
- s1 only gets concatenated with "winter " because of the statement
s1 += "winter "; which is written out in full s1 = s1 + "winter ";
thus resulting in modification of s1.
- s2 is never modified.

Greetz

J
18 years ago