Determine all sequences of integers $a_1, a_2,. . .,$ such that:
(i) $1 \le  a_i \le n$ for all $1 \le i \le n$.
(ii) $| a_i - a_j| = | i - j |$ for any $1 \le i, j \le n$
To determine all sequences of integers \(a_1, a_2, \ldots, a_n\) that satisfy the given conditions, we will analyze the constraints step by step.

1. **Given Conditions:**
   - \(1 \le a_i \le n\) for all \(1 \le i \le n\).
   - \(|a_i - a_j| = |i - j|\) for any \(1 \le i, j \le n\).

2. **Analyzing the Absolute Difference Condition:**
   - Consider the condition \(|a_i - a_j| = |i - j|\). This implies that the difference between the values of the sequence elements \(a_i\) and \(a_j\) is exactly the same as the difference between their indices \(i\) and \(j\).

3. **Examining Boundary Cases:**
   - Let's examine the boundary cases where \(i = 1\) and \(j = n\):
     \[
     |a_n - a_1| = |n - 1|
     \]
     This simplifies to:
     \[
     |a_n - a_1| = n - 1
     \]
     Since \(1 \le a_i \le n\), the only way for \(|a_n - a_1| = n - 1\) to hold true is if \(a_n\) and \(a_1\) are at the extreme ends of the range \([1, n]\). Therefore, we have two possible cases:
     - \(a_1 = 1\) and \(a_n = n\)
     - \(a_1 = n\) and \(a_n = 1\)

4. **Constructing the Sequence for Each Case:**
   - **Case 1: \(a_1 = 1\) and \(a_n = n\)**
     - We need to ensure that \(|a_i - a_j| = |i - j|\) for all \(1 \le i, j \le n\). If we set \(a_i = i\), then:
       \[
       |a_i - a_j| = |i - j|
       \]
       This satisfies the condition. Therefore, one possible sequence is:
       \[
       a_i = i \quad \text{for} \quad 1 \le i \le n
       \]

   - **Case 2: \(a_1 = n\) and \(a_n = 1\)**
     - Similarly, we need to ensure that \(|a_i - a_j| = |i - j|\). If we set \(a_i = n + 1 - i\), then:
       \[
       |a_i - a_j| = |(n + 1 - i) - (n + 1 - j)| = |i - j|
       \]
       This satisfies the condition. Therefore, another possible sequence is:
       \[
       a_i = n + 1 - i \quad \text{for} \quad 1 \le i \le n
       \]

5. **Conclusion:**
   - The sequences that satisfy the given conditions are:
     - \(a_i = i\) for \(1 \le i \le n\)
     - \(a_i = n + 1 - i\) for \(1 \le i \le n\)

The final answer is \( \boxed{ \{a_i = i \text{ for } 1 \le i \le n\} \text{ and } \{a_i = n + 1 - i \text{ for } 1 \le i \le n\} } \)