Which of the following will be the correct result of the statement b = a in the C#.NET code snippet given below? struct Address { private int plotno; private String city; } Address a = new Address(); Address b; b = a;

- Online Exam Test Papers | - MCQs[multiple choice questions and answers ] | - Mock Test Papers | - Practice Papers | - Sample Test Papers |

Question:
Which of the following will be the correct result of the statement b = a in the C#.NET code snippet given below?  struct Address {     private int plotno;     private String city;  } Address a = new Address();  Address b;  b = a;

1.All elements of a will get copied into corresponding elements of b.

2.Address stored in a will get copied into b.

3.Once assignment is over a will get garbage collected.

4.Once assignment is over a will go out of scope hence will die.


More MCQS Questions and answers

R4R Team
R4Rin Top Tutorials are Core Java,Hibernate ,Spring,Sturts.The content on R4R.in website is done by expert team not only with the help of books but along with the strong professional knowledge in all context like coding,designing, marketing,etc!