Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #32201
| Path | csiph.com!optima2.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!1.eu.feeder.erje.net!weretis.net!feeder4.news.weretis.net!feeder1.news.weretis.net!news.mb-net.net!open-news-network.org!.POSTED!not-for-mail |
|---|---|
| From | Marcel Mueller <news.5.maazl@spamgourmet.org> |
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: Array initialization |
| Date | Thu, 30 Jul 2015 01:07:11 +0200 |
| Organization | MB-NET.NET for Open-News-Network e.V. |
| Lines | 13 |
| Message-ID | <mpbmb0$snf$3@gwaiyur.mb-net.net> (permalink) |
| References | <Array-20150729080212@ram.dialup.fu-berlin.de> |
| NNTP-Posting-Host | aftr-37-24-147-20.unity-media.net |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=ISO-8859-15; format=flowed |
| Content-Transfer-Encoding | 7bit |
| X-Trace | gwaiyur.mb-net.net 1438211232 29423 37.24.147.20 (29 Jul 2015 23:07:12 GMT) |
| X-Complaints-To | abuse@open-news-network.org |
| NNTP-Posting-Date | Wed, 29 Jul 2015 23:07:12 +0000 (UTC) |
| User-Agent | Mozilla/5.0 (OS/2; Warp 4.5; rv:24.0) Gecko/20100101 Thunderbird/24.8.1 |
| In-Reply-To | <Array-20150729080212@ram.dialup.fu-berlin.de> |
| Xref | csiph.com comp.lang.java.programmer:32201 |
Show key headers only | View raw
On 29.07.15 08.06, Stefan Ram wrote:
> Recently, being away from the keyboard, I wondered whether
> the following was legal in Java:
>
> public final class Main
> { public static void main( final java.lang.String[] args )
> { int a[] ={ 0, a[ 0 ] + 1, a[ 1 ]+ 1 };
Check for the operator precedence and the execution order and it is obvious.
The operator = is the last one executed. At this point the array already
exists.
Marcel
Back to comp.lang.java.programmer | Previous | Next — Next in thread | Find similar | Unroll thread
Re: Array initialization Marcel Mueller <news.5.maazl@spamgourmet.org> - 2015-07-30 01:07 +0200 Re: Array initialization Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2015-07-30 05:10 +0000
csiph-web