
C# Lesson 11
Lesson 11 in our series about learning C# teaches you about working with using boolean operators to control logic flow.

Author
Characters, the data type that's just a little less useful than a string.
The while statement is simple loop. As long as the condition inside the while() evaluates to true, the section of code will keep repeating itself.
Afterwards you can continue to the next lesson!
Or go back and review the previous lesson.
We also have the source code on GitHub.
using System;
namespace Lesson8
{
class Characters
{
static void Main(string[] args)
{
// b
// 2
// !
// Ñ
Console.OutputEncoding = System.Text.Encoding.UTF8;// Add this last
char myFirstChar = 'Ñ';
Console.WriteLine("Char: " + myFirstChar + " | Int: " + Convert.ToInt32(myFirstChar));
for (int x = 1; x <= 209; x++)
{
char numberToChar = Convert.ToChar(x);
Console.WriteLine($"count {x} : {numberToChar}"); // Show ascii/unicode table after this
}
}
}
}
/*
* TASK:
* Make a for loop that starts at 97 and goes to 122 (includes 122).
* Convert the integer you use for the for loop into a char and print it.
* It will print a lowercase letter.
* Then print the same letter but in uppercase in the same loop.
*
* You can use https://en.wikipedia.org/wiki/List_of_Unicode_characters as a reference.
*/
using System;
namespace Lesson8Task
{
class CharactersTask
{
static void Main(string[] args)
{
}
}
}
We have similar articles. Keep reading!
Lesson 11 in our series about learning C# teaches you about working with using boolean operators to control logic flow.
Author
Lesson 12 in a our series about learning C# teaches you about working with methods.
Author
Lesson 10 in a our series about learning C# teaches you about working with arrays.
Author
$9.99/mo
Unlock every tool, template, and asset with one subscription. Whether you're building a world, writing a story, or running a campaign, go further with expanded storage, AI features, and monthly content drops. No ads, no limits—just pure creative focus. You've started something great—upgrade to bring your vision fully to life.