Problem Description

Task: swap two ints without temp using + and - and return [b,a].

Input Format

Java method

Output Format

Return value

Constraints

Assume no overflow.

Solutions (0)

No solutions submitted yet. Be the first!

Discussion (0)

No comments yet. Start the discussion!

Prev Next