Created
January 8, 2024 17:30
-
-
Save QRemark/472a1ab0128610e99be12f2bf9335840 to your computer and use it in GitHub Desktop.
Перестановка местами значений
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Globalization; | |
using System.Linq; | |
using System.Security.Policy; | |
using System.Text; | |
using System.Threading.Tasks; | |
namespace homeWork1 | |
{ | |
internal class Program | |
{ | |
static void Main(string[] args) | |
{ | |
string firstName = "Fisher"; | |
string lastName = "Bob"; | |
string internalInaformation; | |
Console.WriteLine($"Изначальное имя: {firstName}."); | |
Console.WriteLine($"Изначальная фамилия: {lastName}."); | |
internalInaformation = lastName; | |
lastName = firstName; | |
firstName = internalInaformation; | |
Console.WriteLine(); | |
Console.WriteLine($"Имя после изменения: {firstName}."); | |
Console.WriteLine($"Фамилия после изменения: {lastName}."); | |
Console.ReadKey(); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment