How does string comparison work exactly? -this is something I've wondered for a while.
- Does C# check the length of each string before checking each character?
- Or does it start looping through and comparing each character individually first?
- Does it continue checking each character even if one character is different, or does it stop after one character is found to be different?
- Or does it not even loop through each character directly?
I know it's a very open-ended bunch of questions but it's something that I haven't been able to find any answers for.
Any answers are appreciated, as well as docs. Cheers!