Skip to content

Instantly share code, notes, and snippets.

@janellbaxter
Created February 19, 2017 22:07
Show Gist options
  • Save janellbaxter/c91b5d0b03465dfc8a30828f9294d3c4 to your computer and use it in GitHub Desktop.
Save janellbaxter/c91b5d0b03465dfc8a30828f9294d3c4 to your computer and use it in GitHub Desktop.
4.4 Concatenation; Programming is Fun: C# Adventure Game (Learn C#)
/*
* 4.4 Concatenation
* Example code from Programming is Fun: C# Adventure Game
* Learn C# (for beginners)
* http://programmingisfun.com/learn/c-sharp-adventure-game
*/
using System;
namespace Adventure
{
class Program
{
static void Main()
{
string CharacterName = "John Doe";
Console.WriteLine("Game Title");
Console.WriteLine("Welcome to ...");
Console.WriteLine("What would you like your character's name to be?");
CharacterName = Console.ReadLine();
Console.WriteLine("Your character is now named " + CharacterName + "!");
Console.ReadKey();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment