Let's denote d(n) as the number of divisors of a positive integer n. You are given three integers a, b and c. Your task is to calculate the following sum:

<image>

Find the sum modulo 1073741824 (230).

Input

The first line contains three space-separated integers a, b and c (1 ≤ a, b, c ≤ 100).

Output

Print a single integer — the required sum modulo 1073741824 (230).

Examples

Input

2 2 2


Output

20


Input

5 6 7


Output

1520

Note

For the first example.

  * d(1·1·1) = d(1) = 1; 
  * d(1·1·2) = d(2) = 2; 
  * d(1·2·1) = d(2) = 2; 
  * d(1·2·2) = d(4) = 3; 
  * d(2·1·1) = d(2) = 2; 
  * d(2·1·2) = d(4) = 3; 
  * d(2·2·1) = d(4) = 3; 
  * d(2·2·2) = d(8) = 4. 



So the result is 1 + 2 + 2 + 3 + 2 + 3 + 3 + 4 = 20.

import java.util.Arrays;
import java.util.HashMap;
import java.util.Scanner;

public class TC
{
    static int[] cnt;
    static int MOD = 1073741824;
    static HashMap<Integer, Integer> res;
    static int findPow( int n, int d )
    {
        long D = d*d;
        int hi = 2;
        int lo = 1;
        
        while( n%D == 0 )
        {
            lo = lo*2;
            hi = hi*2;
            D = D*D;
        }
        
        int res = lo;
        
        while( lo <= hi )
        {
            int mid = ( lo + hi )/2;
            
            D = (long)Math.pow( d, mid );
            
            if( n%D == 0 )
            {
                res = Math.max( res, mid );
                lo = mid+1;
            }
            
            else
                hi = mid-1;
        }
        
        return res;
    }
    
    static void init( int A, int B, int C )
    {
        cnt = new int[ A*B*C+1 ];
        res = new HashMap();
        
        Arrays.fill( cnt, 0 );
        cnt[ 1 ] = 1;
        
        for( int a=1; a<=A; a++ )
        {
            for( int b=1; b<=B; b++ )
            {
                for( int c=1; c<=C; c++ )
                {
                    int i = a*b*c;
                
                    if( cnt[ i ] > 0 )
                        continue;
                int div = -1;
            for( int j=2; j<i; j++ )
            {
                if( i%j == 0 )
                {
                    div = j;
                    break;
                }
            }
            
            if( div == -1 )
            {
                cnt[ i ] = 2; // prime
                continue;
            }
            
            // Remove all factors of div from the i
            
            /*int pow = 0;
            int num = i;
            
            while( true )
            {
                if( num %div == 0 )
                {
                    pow++;
                    num /= div;
                }
                
                else
                    break;
            } */
            
            int pow = findPow( i, div );
            
            int rem = i / ( int) Math.pow( div , pow );
            
            cnt[ i ] = cnt[ rem ]*( pow+1 ); 
            cnt[ i ] = cnt[ i ] % MOD;
                }
            }
        }
        
        
         //print();
    }
    
    static void print()
    {
        for( int i = 1; i<cnt.length; i++ )
        {
            System.out.println( i + " " + cnt[ i ]);
        }
    }
    
    static void solve( int a, int b, int c )
    {
        int N = a*b*c;
        init( a, b, c );
        
        int res = 0; 
        
        for( int i=1; i<=a; i++ )
        {
            for( int j=1; j<=b; j++ )
            {
                for( int k=1; k<=c; k++ )
                {
                    N = i*j*k;
                    res += cnt[ N ];
                    res = res % MOD;
                    
                }
            }
        }
        
        System.out.println( res %MOD );
    }
    
    public static void main( String[] args ) throws Exception
    {
        Scanner s = new Scanner( System.in );
        int a = s.nextInt();
        int b = s.nextInt();
        int c = s.nextInt();
        
        solve( a, b, c );
        
        
        
    }
           
}