Recursive program for generating and printing all permutations of the numbers 1, 2, ..., n for given integer number n
Single responsibility principle
Think about the possible reuse of your code. More specifically, the permute method. Do you think that the caller will always want to print out the result? Right now storing the permutations in a variable is impossible, so I cannot use this as a building block for bigger programs. What about printResult it does not only print the result, it also takes care of duplicates.
In general each method does many things, even asking for global variables around the class (printResult accesses n)
I would write follow this stub:
public class Permutation extending Array {
    public static Sequence[Sequence[Any]] permutations(Sequence[Any] array) {
        // implementation 
    }
}

public class PermutationUptoApplication {
    public static void main(String[] args) {
        int upperLimit = (new Scanner(System.in)).nextInt()
        System.out.println(Range(1, upperLimit).toArray().permutations().join(&quot;\n&quot;));
}

You see that I wrote this in pseudo-code, but the main concept is that now you can import the Permutation class from anywhere and call it and reuse the result.
The application class just handles input and output and generates the range of numbers.