0% found this document useful (0 votes)
12 views4 pages

3# User Input ReadLine Read ReadKey

The document contains multiple C# programs that demonstrate different ways to read user input, including reading strings, characters, and key presses. Each program prompts the user for input and displays a response based on the input received. The examples illustrate basic console input and output operations in C#.

Uploaded by

Lesunter KLter
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views4 pages

3# User Input ReadLine Read ReadKey

The document contains multiple C# programs that demonstrate different ways to read user input, including reading strings, characters, and key presses. Each program prompts the user for input and displays a response based on the input received. The examples illustrate basic console input and output operations in C#.

Uploaded by

Lesunter KLter
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

3# User Input ReadLine Read ReadKey

using System;
namespace darklter
{
class Program
{
static void Main(string[] args)
{
string name;

[Link]("Name : ");
name = [Link]();

[Link]("I' am " + name);


}
}
}

|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|||||||||||||||||||||||||||||||||||||||||||

using System;
namespace darklter
{
class Program
{
static void Main(string[] args)
{
char letter;

[Link]("Letter : ");
letter = (char)[Link]();

[Link](letter);
}
}
}

|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|||||||||||||||||||||||||||||||||||||||||||

using System;
namespace darklter
{
class Program
{
static void Main(string[] args)
{
int letter;

[Link]("Letter : ");
letter = [Link]();

[Link](letter);
}
}
}

|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|||||||||||||||||||||||||||||||||||||||||||

using System;
namespace darklter
{
class Program
{
static void Main(string[] args)
{
char letter;

[Link]("Press a Letter");
letter = [Link]().KeyChar;

[Link](" You Press " + letter);


}
}
}

|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|||||||||||||||||||||||||||||||||||||||||||

using System;
namespace darklter
{
class Program
{
static void Main(string[] args)
{
[Link]("tang ina mo");
[Link]();
[Link]("tang ina mo rin");
[Link]();
[Link]("suntukan");
[Link]();
[Link]("tara bading ka nm");
[Link]();
}
}
}

|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|||||||||||||||||||||||||||||||||||||||||||

using System;
namespace darklter
{
class Program
{
static void Main(string[] args)
{
string name, location, learning;

[Link]("Name : ");
name = [Link]();
[Link]("Location : ");
location = [Link]();

[Link]("Learning : ");
learning = [Link]();

[Link]();
[Link]("Hi my name is " + name);
[Link]();
[Link]("I' am From " + location);
[Link]();
[Link]("I study in " + learning);
[Link]();
}
}
}

You might also like