Integer Addition

Your task is to write a function add that adds two int values it is given and returns the result.

Simple positive addition
NOT EXECUTED
Simple negative addition
NOT EXECUTED
Fuzzing
NOT EXECUTED
Reference solution

Pointer swap

Your task is to write a function swap that takes two int pointers and swaps their contents. The function should not modify the values of the pointers.

Also try to solve this problem without using any temporary variable.

Simple swap
NOT EXECUTED
Fuzzing
NOT EXECUTED
Reference solution

Finding Primes

Complete the function is_prime such that it returns 0 if the number is not prime and 1 if it is.

Note: you do not need to handle non-positive numbers.

Simple non-prime test
NOT EXECUTED
Simple prime test
NOT EXECUTED
Non-prime test
NOT EXECUTED
Reference solution