AllTheTimeWorld.com

csharp stringsStrings in C#

Strings in C#

Learn C# (C sharp) in FREE step-by-step lessons.

Strings in C#

Work with Strings; Built-in functions; Validate input; Regular Expressions; Word Games

There are many functions for working with strings.
For instance, you can extract just part of a string, tell if one string is embedded inside another string, and replace one string with another.

In order to do this you will:

Please study the material at each of the links below.

  1. Microsoft Reference Microsoft Reference: Strings and String methods

  2. String Functions: Examples of the most used string methods

  3. String Length: Length gives the number of ALL characters in the String

  4. String Substr: Substr extracts a portion of a string

  5. Names: Using String Functions: Split name into first and last

  6. Escape Sequence: \ and @ Escape Sequence: \ and @: Using the \ and @ with strings with special characters
    /csharp/videos/csharp-escape.mp4
  7. String is valid Social Security Number.: A valid Social Security number has 9 digits

  8. Regular Expressions: A regular expression is a way to determine if a string matches a pattern.

  9. Regular Expressions for a sentence: A sentence must have letters of the alphabet and end with . ? or !

  10. Regular Expression for Robot: R2D2, C3P0?: Regex robotregx= new Regex(@"([A-Z][0-9]){2}");

  11. Regular Expression Drill: Test your understanding

  12. Scramble Array Algorithm Scramble Array Algorithm: Easy algorithm to scramble an array
    /videos/scramble.mp4
  13. Anagram Demo: An anagram is simply the letters of the word scrambled

  14. Anagrams: Details for creating the form

  15. Cryptogram Demo: A cryptogram shuffles the alphabet to create a code

  16. Cryptograms: Details for creating the form

  17. Comparing strings: Download the PDF file

Active Learning

Create a strong password from song.