In java one can initialize an array during declaration as follows
int a[] = {1,23,66,100}; How does one do this in NetRexx ? a = int[] ?????? Thanks satguru ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ To unsubscribe from this mailing list ( ibm-netrexx ), please send a note to [hidden email] with the following message in the body of the note unsubscribe ibm-netrexx <e-mail address> |
try this: a = [int 1, 23, 66, 100] NetRexx's array initialisation is more like JavaScript than Java.... -- dIon Gillard, Multitask Consulting Work: http://www.multitask.com.au Play: http://www.trongus.com I've just returned from THE Java Programming Conference, http://www.SoftwareSummit.com - be there next year
In java one can initialize an array during declaration as follows int a[] = {1,23,66,100}; How does one do this in NetRexx ? a = int[] ?????? Thanks satguru ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ To unsubscribe from this mailing list ( ibm-netrexx ), please send a note to [hidden email] with the following message in the body of the note unsubscribe ibm-netrexx <e-mail address> |
In reply to this post by Satguru Srivastava
That works.
Also found out that if the method or class is declared as binary then the following works too a = int[] [1,23,66,100] Thanks Satguru >>> <[hidden email]> 12/27/99 10:18PM >>> try this: a = [int 1, 23, 66, 100] NetRexx's array initialisation is more like JavaScript than Java.... -- dIon Gillard, Multitask Consulting Work: http://www.multitask.com.au Play: http://www.trongus.com I've just returned from THE Java Programming Conference, http://www.SoftwareSummit.com - be there next year "Satguru Srivastava" <[hidden email]> Sent by: [hidden email] 28/12/99 04:07 To: <[hidden email]> cc: Subject: Initializing an array during declaration In java one can initialize an array during declaration as follows int a[] = {1,23,66,100}; How does one do this in NetRexx ? a = int[] ?????? Thanks satguru ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ To unsubscribe from this mailing list ( ibm-netrexx ), please send a note to [hidden email] with the following message in the body of the note unsubscribe ibm-netrexx <e-mail address> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ To unsubscribe from this mailing list ( ibm-netrexx ), please send a note to [hidden email] with the following message in the body of the note unsubscribe ibm-netrexx <e-mail address> |
In reply to this post by Satguru Srivastava
> From: "Satguru Srivastava" <[hidden email]> > Also found out that if the method or class is declared as binary then > the following works too > > a = int[] [1,23,66,100] If you are in a binary method or class, you can be lazy and omit the int[] part. It will be infered correctly. Martin -- [hidden email] Team OS/2 http://www.multimania.com/lafaix ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ To unsubscribe from this mailing list ( ibm-netrexx ), please send a note to [hidden email] with the following message in the body of the note unsubscribe ibm-netrexx <e-mail address> |
Free forum by Nabble | Edit this page |