"static" is useless here:
static int stock = 20;
Why do you not print "stock" instead of copying its value to "plus"?
int plus = ++stock;
"static" is useless here:
static int stock = 20;
Why do you not print "stock" instead of copying its value to "plus"?
int plus = ++stock;