cklangford98 cklangford98
  • 02-03-2018
  • Computers and Technology
contestada

Given the code below, what would output to the Console Window?

Think carefully on this one...it is tricky!
C#
1
string a = ”10”;
2
string b = “20”;
3
Console.WriteLine(a+b+5);

Respuesta :

spikespaz
spikespaz spikespaz
  • 03-03-2018
I don't know C# but based on experiences in other OOP languages and languages in general, you get a type error, whatever format that may be for C#. You cannot concatenate "10" and "20" as strings and then attempt to add an integer 5 unless the language has inferred type coercion.
Answer Link

Otras preguntas

"Love is the great intangible. In our nightmares, we can create beasts out of pure emotion. Hate stalks the streets with dripping fangs, fear flies down narrow
please someone help me please due in 10 min
Write a brief description of yor idea for the abstract artwork. What is the feeling are you communicating in your work? what shapes and colors will you include.
ahhh if someone can,please answer asap! 20 points!
how did the naturalization act change the residency requirement?
PLSSS HELPPPP I WILLL GIVE YOU BRAINLIEST!!!!!! PLSSS HELPPPP I WILLL GIVE YOU BRAINLIEST!!!!!! PLSSS HELPPPP I WILLL GIVE YOU BRAINLIEST!!!!!! PLSSS HELPPPP I
What is the y-intercept in the equation y=4x-3?
pls i don’t understand i need help! i’ll give brainliest
Solve for c: c + (-20) = -14
going to send you a picture of my question. ​