Reading strings from the keyboard, DOT NET Programming

Reading strings from the keyboard  

using System;
class Prog3_1
  public static void Main()
   Console.Write ("Enter Your First Name : "); // Displaying to write first name
   string name1 = Console.ReadLine (); // Saving first name in name1
   Console.Write ("Enter Your Last Name : "); // Displaying to write last name
   string name2 = Console.ReadLine (); // Saving first name in name2
   Console.WriteLine ("Hello Mr." + name1 +" " + name2); // Displaying both first & last names
   Console.ReadLine (); // Since to stop the console for displaying last line, we use this to accept a
keystroke frm user. (Similar to getch() in C)

Posted Date: 2/11/2013 2:55:14 AM | Location : United States

Related Discussions:- Reading strings from the keyboard, Assignment Help, Ask Question on Reading strings from the keyboard, Get Answer, Expert's Help, Reading strings from the keyboard Discussions

Write discussion on Reading strings from the keyboard
Your posts are moderated
Related Questions
What are major difference between classic ADO and ADO.NET ? Some major differences between the classic ADO & ADO.NET are as follows: 1) As in the classic ADO we had server a

Finding Maximum & Minimum Numbers - C# Program I am facing some problems in the code for Finding Maximum & Minimum Numbers. Can anybody suggest me the proper code for it.

Question: (a) Prepare a diagram which explains where the different elements like Form, Window and Document, belong in the Document Object Model hierarchy and how properties are

What is CodeDom The "CodeDom" is an object model that represents actually a source code. It is designed for language independent - once you create a "CodeDom" hierarchy for a p

Wowza expert required Project Description: Seeking wowza expert to teach our webmaster. To provide: How configure wowza to live transcoder. How allow add live transc

Project Description I require a Automated penny auction bidder software (bidder robot, sniper software, Autobidder ) that put bid at specific milliseconds Nanoseconds from the e

What are tuples? Tuple is a fixed-size collection that can have elements of either similar or different data types. Same to arrays, a user must have to specify the size of a tu

What is ViewState? The Viewstate is built-in structure for automatically retaining the values among the multiple requests for the similar page. The viewstate is internally main

What are the methods provided by the command object? The command objects used to connect the connection object to the Datareader or the dataset. The command object provided som