Advertisement
LeRoY_Go

Untitled

Jun 15th, 2020
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.06 KB | None | 0 0
  1. static void DeleteDossier(ref string[] fullName, ref string[] post)
  2. {
  3. Console.Write("Ввидите номер досье: ");
  4. int index = Convert.ToInt32(Console.ReadLine()) - 1;
  5. string[] Arrey;
  6. for (int i = 0; i < 2; i++)
  7. {
  8. if (i == 1)
  9. {
  10. Arrey = fullName;
  11. }
  12. else
  13. {
  14. Arrey = post;
  15. }
  16. string[] tempArrey = new string[Arrey.Length - 1];
  17. for (int j = 0; j < index; j++)
  18. {
  19. tempArrey[j] = Arrey[j];
  20. }
  21. for (int j = index; j < tempArrey.Length; j++)
  22. {
  23. tempArrey[i] = Arrey[i + 1];
  24. }
  25. if (i == 1)
  26. {
  27. fullName = tempArrey;
  28. }
  29. else
  30. {
  31. post = tempArrey;
  32. }
  33. }
  34. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement