Users Pricing

forum

Home Forums Starting Index of Arrays in C# and VB.Net – MindStick

Starting Index of Arrays in C# and VB.Net

Anonymous User 4145 08 Apr 2013
Hi All!

Have a look at the following code.,

C#

 string[] testString = new string[jobs.Count];
Equivalent VB.Net

Dim testString() As String = New String(jobs.Count - 1) {}
Why it is taking 'jobs.Count - 1' instead 'jobs.Count' in vb.net while creating new arrays?

Advance thanks!

1 Answers

Markdown for AI

A clean, structured version of this page for AI assistants and LLMs.

Open .md