#include <iostream>
#include <ctime>
using namespace std;

#define DIM 20
#define VMIN 1
#define VMAX 100

void ROTAZIONE(int arr[]);

int main(void) {
	int arr[DIM];
	int i;
	
	cout << "Prima: ";
	
	srand(time(0));
	
	for (i = 0; i < 4; i++) {
		arr[i] = rand() % (VMAX - VMIN + 1) + VMIN;
		cout << arr[i] << " ";
	}
	
	cout << endl;
	
	ROTAZIONE(arr);
	
	cout << "Dopo: ";
	
	for (i = 0; i < 4; i++) {
		cout << arr[i] << " ";
	}
	
	cout << endl;
	
	return 0;
}

void ROTAZIONE(int arr[]) {
	int temp = arr[0];
	arr[0] = arr[3];
	arr[3] = temp;
}