// Arup Guha
// 2/16/2023
// Solution to 2022 NAQ Problem L: Spidey Distance

import java.util.*;
import java.io.*;

public class spideydistance {

	public static void main(String[] args) {
	
		// Get input.
		Scanner stdin = new Scanner(System.in);
		long t = stdin.nextLong();
		long s = stdin.nextLong();
		long[] res = solve(t, s);
		
		// Taxi is too big, answer is 1.
		if (res == null)
			System.out.println(1);
		
		// Solve this case...
		else {
			long d = gcd(res[0], res[1]);
			System.out.println((res[0]/d) + "/" + (res[1]/d) );
		}
	}
	
	// Returns the fraction for taxi cab distance t, spidey distance s.
	public static long[] solve(long t, long s) {
		
		// How far to extend.
		long extend = s/3;
		
		// How I indicate a probability of 1.
		if (t >= s + extend) return null;
		
		// This is easy, no illegal taxi cab points.
		if (t <= s)
			return new long[]{manhattan(t), spidey(s)};
			
		// Here t > s and t < s+extend. So we only want to count the taxicab pts in the spidey distance that are reachable.
		long add = spidey(s, t-s);
		return new long[]{manhattan(s)+add, spidey(s)};
	
	}

	// Sum of two squares...
	public static long manhattan(long n) {
		return 2*n*n + 2*n + 1;
	}
	
	// Returns the # of points reachable in spidey distance n.
	public static long spidey(long n) {
		
		// Start with these, add in rest.
		long tmp = manhattan(n);
		
		// Wanted to avoid negative stuff.
		if (n<3) return tmp;
		
		// # of pts we add (in scan lines) is arithmetic series with common difference 3.
		// first and last terms are delineated below. This is count for one quadrant.
		long last = n-2;
		long first = last%3;
		long numTerms = (last-first)/3+1;
		
		// Multiply pt count by 4...so times 4 divided by 2 is just mult 2...
		return tmp + 2*(first+last)*numTerms;
	}
	
	// Returns the # of pts that are longer than distance n by manhattan distance, but are within n+k
	// of manhattan distance 
	public static long spidey(long n, long k) {
		
		// Arithmetic series...I did difference -3 since we are counting down.
		long first = n-2;
		long last = first - (k - 1)*3;
		
		// This is the partial sum we want (of the whole series in the previous function.)
		return (first+last)*k*2;
	}
	
	public static long gcd(long a, long b) {
		return b == 0 ? a : gcd(b, a%b);
	}
}