Advertisement
JohnJuly

Homework5

Oct 3rd, 2023
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.63 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6.  
  7. namespace Homework5
  8. {
  9.     internal class Program
  10.     {
  11.         static void Main(string[] args)
  12.         {
  13.             string name = "Smith";
  14.             string surname = "John";
  15.             string secondSurname;
  16.  
  17.             Console.WriteLine($"Имя: {name} , Фамилия: {surname}");
  18.            
  19.             secondSurname = name;
  20.             name = surname;
  21.             surname = secondSurname;
  22.  
  23.             Console.WriteLine($"Имя: {name} , Фамилия: {surname}");
  24.         }
  25.     }
  26. }
  27.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement