Skip to content

Instantly share code, notes, and snippets.

View JamesC01's full-sized avatar

James JamesC01

  • United Kingdom
View GitHub Profile
@JamesC01
JamesC01 / tictactoe.c
Last active March 10, 2025 06:58
A simple tic-tac-toe game written in C. My first larger C program.
// Tic Tac Toe in C. V1.0 by James 26/05/2019
// This is my first bigger C project. It was actually a lot easier than a I
// thought it would be! It's not great, but it works perfectly decently.
// I started working on it sometime around 4 in the morning, and I'm done before
// 7 in the morning. So I didn't spend much time on it.
// Also, I can't really claim I did the check function myself, though. The first time
// I ever made tic tac toe (in C#), I ended up writing looping functions which could
@JamesC01
JamesC01 / Program.cs
Created September 22, 2017 23:54
Pokemon-style Battle Game
class Program
{
// This is a Pokemon style text-based battle game.
static void Main(string[] args)
{
bool playing = true;
Console.Write("Enter your battle monster's name: ");
string playerName = Console.ReadLine();
@JamesC01
JamesC01 / Program.cs
Created September 22, 2017 22:56
Random username generator
static void Main(string[] args)
{
string username = ChooseRandomAdjective() + ChooseRandomNoun();
Console.WriteLine(username); username = ChooseRandomAdjective() + ChooseRandomNoun();
Console.WriteLine(username); username = ChooseRandomAdjective() + ChooseRandomNoun();
Console.WriteLine(username); username = ChooseRandomAdjective() + ChooseRandomNoun();
Console.WriteLine(username); username = ChooseRandomAdjective() + ChooseRandomNoun();
Console.WriteLine(username); username = ChooseRandomAdjective() + ChooseRandomNoun();
Console.WriteLine(username);
Console.ReadLine();