Most optimized algorithm for incrementing squares Write the "fastest" program to print an incrementing series of squares from a given input to a given input.

Example input:

-2
7


Example output:

4, 1, 0, 1, 4, 9, 16, 25, 36, 49


When using a "cryptic" language, please post the pseudocode, in addition to your program.

The entries will be judged on the most efficient algorithm.
The tag says "code-challenge", but I don't see any challenge. Just some mathematics we studied when I was about 12.

import java.util.*;

public class IncSquares
{
    public static void main(String[] args)
    {
        Scanner in = new Scanner(System.in);
        int min = in.nextInt();
        int max = in.nextInt();

        int sq = min * min;
        System.out.print(sq);
        while (min &lt; max) {
            sq += (min &lt;&lt; 1) + 1;
            min++;
            System.out.print(", " + sq);
        }
        System.out.println();
    }
}