/+ dub.sdl:
	name "hello"
+/
import std.algorithm;
import std.conv;
import std.stdio;
import std.string;

void main()
{
    auto N = readln.chomp.to!int;
    auto A = readln.chomp.to!int;

    writeln(N * N - A);
}
