will this code works fine? or will it gives error?

Object obj=5;
int i=6;
i=i+obj;

Answer Posted / somnath nanekar

it will give an error...(we hv to typecast object to int)

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which approach provides better support for test driven development - asp.net mvc or asp.net webforms?

504


List out few different return types of a controller action method?

609


What is renderbody?

547


Can you use Razor code in Javascript in ASP.Net MVC?

663


Can you explain renderbody and renderpage in asp.net mvc?

554






What is separation of concerns in asp.net mvc?

597


What is rxjava used for?

659


What are the advantages of asp.net mvc?

558


What is an asynchronous controller in asp.net mvc?

541


What is entitytypes? : Entity framework

612


Can I add mvc testcases in visual studio express?

590


What are the main features of asp.net mvc 4 used by asp.net web api?

549


What is the difference between viewbag and viewdata in mvc?

531


What is the version number for the next version of the .net framework, codenamed �orcas�?

483


Mention what is the difference between “ActionResult” and “ViewResult” ?

577