String[] a = new string[10]
for(i=0; i<10; i++)
{
a[i] = i;
}
How many heap object will be created for this array. Choose
the answer below.
Ans: 1, 10, 11, 12
Answers were Sorted based on User's Feedback
Answer / dennis
11.
1 for the String[]
and 1 for each individual "string" in the string array.(so total 10)
| Is This Answer Correct ? | 1 Yes | 1 No |
Answer / suresh
ANS:11
VALUES ARE STORED IN ARRAY FROM 0.HERE STRING[].
HERE TOTAL I VALUE IS 10 AND IT IS STORED IN ARRAY INCLUDING
STARTING POINT.SO 10+1=11.SO
| Is This Answer Correct ? | 1 Yes | 2 No |
How to create a key pair in .net?
What does .net stand for?
How many types of generations are there in a garbage collector?
What is difference between .net core and .net standard?
What is PageIndex in DataGrid?What is the event used in the Datagrid for while moving from one page to another page in the Grid?write code for it
What is stored procedure ? how we use it in .NET ?
Can we Classic ASP,.Net 1.0, .Net 1.x and .Net 2.0 installed on the same system?
Explain the difference between garbage collections in .net 4.0 and earlier versions?
Please send me the latest asp.net,c#,sql server interview questions .my email id is ramtryin@gmail.com
How does the .NET framework work?
Sql Queries: A Table will be given Omiting Duplicate rows and adding a new column
What is the difference between server.transfer and response.redirect? Why?