BasicKnowledgeCSharp/LessonsAndTasks/Lesson 41 - Оператор присваивания объединения со значением NULL/Program.cs
Dvurechensky 058c8f2679 1.0
Main
2024-10-05 09:59:53 +03:00

16 lines
406 B
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/*
* Оператор присваивания объединения со значением NULL ??=
*/
using System;
class Program
{
static void Main()
{
string str = null;
//возвращает другую строку если получили NULL - ее длинну
//str ??= "def";
//Console.WriteLine(str.Length);
Console.ReadKey();
}
}