|
-
Mar 27th, 2002, 07:34 PM
#1
Thread Starter
Member
"Hello C-Sharp!" question
I'm just poking around in C# and I just wrote the classic Hello < insert new lang here > program. It will run in the console, then exit fast. Doesn't give me a second to read the text. I remember having this issue when I poked around in C some, but I can't remember what I did to get around it.
-
Mar 27th, 2002, 08:23 PM
#2
Frenzied Member
put Console.Readline(); below "hello world";
Dont gain the world and lose your soul
-
Mar 27th, 2002, 08:47 PM
#3
Thread Starter
Member
Thanks.
Code:
using System;
class HelloWorld {
static void Main() {
Console.WriteLine("Hello C#!");
Console.ReadLine();
}
}
-
Mar 27th, 2002, 10:01 PM
#4
Also i believe you can add
while (false)
{
}
-
Apr 11th, 2002, 10:38 AM
#5
If you are using the .net studio you can run it by using ctrl+f5 (as opposed to just f5) that will leave the dos window open for you.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|