Ask your own question, for FREE!
Computer Science 17 Online
OpenStudy (anonymous):

Can I get some help with this Program Please it is in C++ and it isn't responding right......

OpenStudy (anonymous):

Module Module1 Sub Main() Dim myInt As Integer = Nothing Console.WriteLine("Please enter an Integer") myInt = Console.ReadLine() Select Case myInt Case 0 Console.ReadLine("Jefferson") Case 1 Console.ReadLine("Washington") Case 2 Console.ReadLine("Lincoln") Case 3 Console.ReadLine("Roosevelt") End Select Console.ReadLine() End Sub End Module

OpenStudy (anonymous):

Can you help me please

OpenStudy (rsadhvika):

this doesnt look C++

OpenStudy (anonymous):

it is written in VB 2010

OpenStudy (rsadhvika):

no idea sorry :(

OpenStudy (anonymous):

the problem I am having is getting to run properly where the names are written is causing it to not run properly

OpenStudy (rsadhvika):

i get what u doing wrong :)

OpenStudy (rsadhvika):

Case 0 Console.ReadLine("Jefferson") Case 1 Console.ReadLine("Washington") Case 2 Console.ReadLine("Lincoln") Case 3 Console.ReadLine("Roosevelt")

OpenStudy (rsadhvika):

if 0, u wanto print Jefferson, right ?

OpenStudy (anonymous):

yes

OpenStudy (rsadhvika):

you should use Console.WriteLine for that

OpenStudy (rsadhvika):

change the code line below it shoudl work

OpenStudy (anonymous):

but the program has to read the different cases of each

OpenStudy (rsadhvika):

Module Module1 Sub Main() Dim myInt As Integer = Nothing Console.WriteLine("Please enter an Integer") myInt = Console.ReadLine() Select Case myInt Case 0 Console.WriteLine("Jefferson") Case 1 Console.WriteLine("Washington") Case 2 Console.WriteLine("Lincoln") Case 3 Console.WriteLine("Roosevelt") End Select Console.ReadLine() End Sub End Module

OpenStudy (anonymous):

I will try it and see if that works

OpenStudy (rsadhvika):

okie doke

OpenStudy (rsadhvika):

good luck :D

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!