output_description: Print the maximum possible value of the greatest common divisor of a sequence
  a_1, a_2, ..., a_N that satisfies the condition.
  
  * * *
input_description: Input is given from Standard Input in the following format:
  
      
      
      N M
attempt: using System;
  using System.Linq;
  using System.Collections.Generic;
  
  namespace Algorithm
  {
      class Program
      {
          static void Main(string[] args)
          {
              var l = Console.ReadLine().Split().Select(int.Parse).ToArray();
              int N = l[0], M = l[1];
  
              if (M % N == 0)
                  Console.WriteLine(M / N);
              else
              {
                  var div = M / N;
                  var rem = M % N;
                  Console.WriteLine(Gcd(div, rem));
              }
          }
  
          static int Gcd(int a, int b)
          {
              if (a < b) Gcd(b, a);
              if (b == 0) return a;
              return Gcd(b, (a % b));
          }
      }
  }
  
problem_description: Statement
  
  You are given integers N and M.
  
  Consider a sequence a of length N consisting of positive integers such that
  a_1 + a_2 + ... + a_N = M. Find the maximum possible value of the greatest
  common divisor of a_1, a_2, ..., a_N.
samples: [{"input": "3 14", "output": "2\n    \n\nConsider the sequence (a_1, a_2, a_3) = (2, 4, 8). Their greatest common\ndivisor is 2, and this is the maximum value.\n\n* * *"}, {"input": "10 123", "output": "3\n    \n\n* * *"}, {"input": "100000 1000000000", "output": "10000"}]