Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace zad4._5
- {
- class Program
- {
- static void Main(string[] args)
- {
- int[] tab1 = { 45, 57, 21, 12, 78, 49, 35,29,57 };
- int[] tab2 = new int [tab1.Length];
- for (int i = 0; i <= tab2.Length - 1; i++)
- {
- if (i == 0)
- {
- tab2[i] = (tab1[tab1.Length - 1]);
- }
- else
- {
- tab2[i] = tab1[i - 1];
- }
- }
- foreach (int x in tab2)
- Console.Write("{0} ", x);
- Console.Read();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement