Language: C++

        #include <bits/stdc++.h>
        #define ll long long
        #define ld long double
        using namespace std; 
        int gcd(int a, int b){
          	if (a == 0) 
       			return b;  
    		return gcd(b % a, a); 
        }
    	int lcm (int a, int b){
         	return a*b/gcd(a,b);
        }
        int main(){
        	ld x;
          	cin >> x;
          	cout << lcm(x, 360)/x << endl;
        	return 0;
        }

Compiler output:
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:58,
                 from a.cc:1:
/usr/include/c++/14/numeric: In instantiation of 'constexpr std::common_type_t<_Mn, _Nn> std::lcm(_Mn, _Nn) [with _Mn = long double; _Nn = int; common_type_t<_Mn, _Nn> = long double]':
a.cc:16:23:   required from here
   16 |                 cout << lcm(x, 360)/x << endl;
      |                         ~~~^~~~~~~~
/usr/include/c++/14/numeric:190:21: error: static assertion failed: std::lcm arguments must be integers
  190 |       static_assert(is_integral_v<_Mn> && is_integral_v<_Nn>,
      |                     ^~~~~~~~~~~~~~~~~~
/usr/include/c++/14/numeric:190:21: note: 'std::is_integral_v<long double>' evaluates to false
In file included from /usr/include/c++/14/bits/stl_pair.h:60,
                 from /usr/include/c++/14/bits/stl_algobase.h:64,
                 from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51:
/usr/include/c++/14/type_traits: In instantiation of 'struct std::make_unsigned<long double>':
/usr/include/c++/14/type_traits:2076:11:   required by substitution of 'template<class _Tp> using std::make_unsigned_t = typename std::make_unsigned::type [with _Tp = long double]'
 2076 |     using make_unsigned_t = typename make_unsigned<_Tp>::type;
      |           ^~~~~~~~~~~~~~~
/usr/include/c++/14/numeric:199:34:   required from 'constexpr std::common_type_t<_Mn, _Nn> std::lcm(_Mn, _Nn) [with _Mn = long double; _Nn = int; common_type_t<_Mn, _Nn> = long double]'
  199 |       _Ct __r = __m2 / __detail::__gcd<make_unsigned_t<_Ct>>(__m2, __n2);
      |                        ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~
a.cc:16:23:   required from here
   16 |                 cout << lcm(x, 360)/x << endl;
      |                         ~~~^~~~~~~~
/usr/include/c++/14/type_traits:1929:13: error: invalid use of incomplete type 'class std::__make_unsigned_selector<long double, false, false>'
 1929 |     { using type = typename __make_unsigned_selector<_Tp>::__type; };
      |             ^~~~
/usr/include/c++/14/type_traits:1837:11: note: declaration of 'class std::__make_unsigned_selector<long double, false, false>'
 1837 |     class __make_unsigned_selector;
      |           ^~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/numeric: In instantiation of 'constexpr std::common_type_t<_Mn, _Nn> std::lcm(_Mn, _Nn) [with _Mn = long double; _Nn = int; common_type_t<_Mn, _Nn> = long double]':
a.cc:16:23:   required from here
   16 |                 cout << lcm(x, 360)/x << endl;
      |                         ~~~^~~~~~~~
/usr/include/c++/14/numeric:205:48: error: argument 1 in call to function '__builtin_mul_overflow' does not have integral type
  205 |       bool __overflow = __builtin_mul_overflow(__r, __n2, &__r);
      |                                                ^~~