Square a number
This page needs a recent browser (with SharedArrayBuffer support). Please update Chrome, Edge, Firefox or Safari to the latest version.
Square a number
Return n multiplied by itself. One line of arithmetic is enough.
Complete int square(int n) so it returns n * n. Do not write main — the checker provides one.
Click Run to see the output here.