How many objects of type string will be created during the following code execution?
  string s = "sdfsg"; 
  if(s.ToLower().Substring(1,2).EndsWith("exe")); 
Explanation
1. "sdfs"
2. Will be created as a result of the s.ToLower ()
3. Will be created as a result of the .Substring ()
4. "exe"

Follow CodeGalaxy

Mobile Beta

Get it on Google Play
Send Feedback
Cosmo
Sign Up Now
or Subscribe for future quizzes