Computer Forums

Member Login

Remember Me? Sign Up! | Forgot Password
 
Slogan
 
Closed Thread
Old 01-15-2009, 09:22 PM   #1 (permalink)
 
Newb Techie

Join Date: Nov 2008

Posts: 2

BioHazard90 is on a distinguished road

Default instantiation in C#

Code:
class MyProgram
{
    static void Main()
    {
        int[] integers;            // declare array
        integers = new int[10];    // size array
    }
}
In which line is the array actually instantiated?
BioHazard90 is offline  
Old 01-15-2009, 11:29 PM   #2 (permalink)
CrazeD's Avatar
 
Wizard Techie

Join Date: Feb 2006

Location: Maine

Posts: 3,683

CrazeD will become famous soon enough

Send a message via AIM to CrazeD Send a message via MSN to CrazeD
Default Re: instantiation in C#

int[] integers;

I believe this.
__________________

Need website help? PM me!
CrazeD is offline  
Old 01-16-2009, 12:17 PM   #3 (permalink)
 
Software Developer

Join Date: Mar 2006

Location: Columbus, OH

Posts: 569

jaeusm is on a distinguished road

Default Re: instantiation in C#

Instantiated means an instance of a type has been created. In C#, that is typically accomplished using the 'new' keyword. In your specific case, the second line of code in the Main method instantiates the array.
jaeusm is offline  
 
Closed Thread

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On