Accenture interview question

Write a function to calculate gcd using recursion