Given two long integers, $\text{min}$ and $\textit{max}$, find and print a common fraction, $\frac{n}{d}$, such that $min\leq d\leq max$ and $|\frac{n}{d}-\pi|$ is minimal (recall that $\pi\approx3.1415926535897932384626433832795028841971693993751$). If there are several fractions having minimal distance to $\textbf{\pi}$, choose the one with the smallest denominator.

Input Format

Two space-separated long integers describing the respective values of $\text{min}$ and $\textit{max}$.

Constraints

$1\le\textit{min}\le\textit{max}\le10^{15}$

Output Format

Print your answer in the form n/d, where $n$ is the numerator of the fraction closest to $\textbf{\pi}$ and $\boldsymbol{d}$ is the denominator of that fraction.

Sample Input 0
1 10

Sample Output 0
22/7

Explanation 0

We must check all fractions with denominators from $\textit{min}=1$ to $max=10$: 

For $\boldsymbol{d}=1$: $\frac{3}{1}\leq\pi\leq\frac{4}{1}$, the closest fraction is $\frac{3}{1}$ and the distance is $\left|\frac{3}{1}-\pi\right|\approx0.142$.
For $\boldsymbol{d}=2$: $\frac{6}{2}\leq\pi\leq\frac{7}{2}$, the closest fraction is $\frac{6}{2}$ and the distance is $\left|\frac{6}{2}-\pi\right|\approx0.142$.
For $\boldsymbol{d}=3$: $\frac{9}{3}\leq\pi\leq\frac{10}{3}$, the closest fraction is $\frac{9}{3}$ and the distance is $\left|\frac{9}{3}-\pi\right|\approx0.142$.
For $\boldsymbol{d}=4$: $\frac{12}{4}\leq\pi\leq\frac{13}{4}$, the closest fraction is $\frac{13}{4}$ and the distance is $\left|\frac{13}{4}-\pi\right|\approx0.108$.
For $\boldsymbol{d}=5$: $\frac{15}{5}\leq\pi\leq\frac{16}{5}$, the closest fraction is $\frac{16}{5}$ and the distance is $\left|\frac{16}{5}-\pi\right|\approx0.058$.
For $\boldsymbol{d=6}$: $\frac{18}{6}\leq\pi\leq\frac{19}{6}$, the closest fraction is $\frac{19}{6}$ and the distance is $\left|\frac{19}{6}-\pi\right|\approx0.025$.
For $\boldsymbol{d}=7$: $\frac{21}{7}\leq\pi\leq\frac{22}{7}$, the closest fraction is $\frac{22}{7}$ and the distance is $\left|\frac{22}{7}-\pi\right|\approx0.001$.
For $\boldsymbol{d}=8$: $\frac{25}{8}\leq\pi\leq\frac{26}{8}$, the closest fraction is $\frac{25}{8}$ and the distance is $\left|\frac{25}{8}-\pi\right|\approx0.017$.
For $\boldsymbol{d}=9$: $\frac{28}{9}\leq\pi\leq\frac{29}{9}$, the closest fraction is $\frac{28}{9}$ and the distance is $\left|\frac{28}{9}-\pi\right|\approx0.030$.
For $\boldsymbol{d}=10$: $\frac{31}{10}\leq\pi\leq\frac{32}{10}$, the closest fraction is $\frac{31}{10}$ and the distance is $\left|\frac{31}{10}-\pi\right|\approx0.042$.

Of these, the closest approximation is $\frac{22}{7}$ with a distance to $\textbf{\pi}$ of about $\boldsymbol{0.001}$, so we print 22/7 as our answer.

Difficulty: MEDIUM_HARD

Solutions:
import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi):
	ExactSoln = None
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
			if i1 >= Min:
				ExactSoln = i1
	if ExactSoln != None:
		return ExactSoln
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Count = 0
	Basis = []
	MaxBasis = 4
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	DenomSet = {Denom}
	TempCount = 0
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
					TempCount += 1
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


__author__ = 'Ward'
import sys
import math
import heapq
(Min, Max) = map(int, sys.stdin.readline().split())
PI = 31415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679
ONE = 10 ** 100
(sN, sD) = (3, 1)
(lN, lD) = (4, 1)
bestN = 3
bestD = 1
bestError = PI - 3 * ONE
backTrackOptions = [(0, 3, 1, 4, 1)]
while True:
	(me, sN, sD, lN, lD) = heapq.heappop(backTrackOptions)
	if me > bestError:
		break
	(N, D) = (sN + lN, sD + lD)
	if D > Max:
		continue
	error = PI - N * ONE // D
	if error > 0:
		heapq.heappush(backTrackOptions, (me, N, D, lN, lD))
		heapq.heappush(backTrackOptions, (abs(error), sN, sD, N, D))
	else:
		heapq.heappush(backTrackOptions, (me, sN, sD, N, D))
		heapq.heappush(backTrackOptions, (abs(error), N, D, lN, lD))
	a = math.ceil(Min / D)
	N = a * N
	D = a * D
	if D >= Min and D <= Max and (abs(error) < bestError):
		bestError = abs(error)
		bestN = N
		bestD = D
print(str(bestN) + '/' + str(bestD))


import sys
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
p = 314159265358979323846264338327950288419716939937510
a = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1]
m = len(a)
con = [[1, a[0]], [a[1], a[0] * a[1] + 1]]
for i in range(2, m):
	con.append([con[i - 2][0] + a[i] * con[i - 1][0], con[i - 2][1] + a[i] * con[i - 1][1]])
subconU = [[1, 4], [2, 7], [3, 10], [4, 13], [5, 16], [6, 19]]
subconL = []
for i in range(0, len(con) - 2):
	if i % 2 == 0:
		for j in range(0, a[i + 2]):
			subconL.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
	else:
		for j in range(0, a[i + 2]):
			subconU.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
subconL.sort()
subconU.sort()
upperbds = []
lowerbds = []
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while lowerbds == []:
	for i in subconL:
		if i[0] >= locmin:
			if i[0] <= locmax:
				lowerbds.append(i)
	if lowerbds == []:
		k = 0
		while subconL[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconL[k][0]
		locmax = locmax - subconL[k][0]
		totalshiftx = totalshiftx + subconL[k][0]
		totalshifty = totalshifty + subconL[k][1]
for i in lowerbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while upperbds == []:
	for i in subconU:
		if i[0] >= locmin:
			if i[0] <= locmax:
				upperbds.append(i)
	if upperbds == []:
		k = 0
		while subconU[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconU[k][0]
		locmax = locmax - subconU[k][0]
		totalshiftx = totalshiftx + subconU[k][0]
		totalshifty = totalshifty + subconU[k][1]
for i in upperbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
lowerbds.sort()
upperbds.sort()
up = upperbds[-1]
down = lowerbds[-1]
denom = 0
num = 0
dist = 100
a = abs(up[1] * 10 ** 50 - p * up[0])
b = abs(down[1] * 10 ** 50 - p * down[0])
if a * down[0] < b * up[0]:
	denom = up[0]
	num = up[1]
else:
	denom = down[0]
	num = down[1]
print(str(num) + '/' + str(denom))


import sys
PI = 31415926535897932384626433832795028841971693993751
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
h = {}
k = {}
h[-1] = 1
h[-2] = 0
k[-1] = 0
k[-2] = 1
Evens = []
Odds = []
a = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6]
semiconvergents = []
for i in range(len(a)):
	h[i] = a[i] * h[i - 1] + h[i - 2]
	k[i] = a[i] * k[i - 1] + k[i - 2]
	if i < len(a) - 1:
		if (i - 1) % 2 == 0:
			for m in range(a[i + 1]):
				semiconvergents.append([k[i - 1] + m * k[i], h[i - 1] + m * h[i]])
				Evens.append([k[i - 1] + m * k[i], h[i - 1] + m * h[i]])
		else:
			for m in range(a[i + 1]):
				semiconvergents.append([k[i - 1] + m * k[i], h[i - 1] + m * h[i]])
				Odds.append([k[i - 1] + m * k[i], h[i - 1] + m * h[i]])
Efrac = []
Eshift = [0, 0]
tempMin = min
tempMax = max
denomShift = 0
numerShift = 0
for x in Evens:
	if min <= x[0] <= max:
		Efrac.append(x)
while Efrac == []:
	for x in Evens:
		if x[0] > tempMin:
			break
		else:
			denomShift = x[0]
			numerShift = x[1]
	tempMin -= denomShift
	tempMax -= denomShift
	Eshift[0] += denomShift
	Eshift[1] += numerShift
	for x in Evens:
		if tempMin <= x[0] <= tempMax:
			Efrac.append(x)
Enumer = Efrac[len(Efrac) - 1][1] + Eshift[1]
Edenom = Efrac[len(Efrac) - 1][0] + Eshift[0]
Edist = abs(Enumer / Edenom - PI)
Ofrac = []
Oshift = [0, 0]
tempMin = min
tempMax = max
denomShift = 0
numerShift = 0
for x in Odds:
	if min <= x[0] <= max:
		Ofrac.append(x)
while Ofrac == []:
	for x in Odds:
		if x[0] > tempMin:
			break
		else:
			denomShift = x[0]
			numerShift = x[1]
	tempMin -= denomShift
	tempMax -= denomShift
	Oshift[0] += denomShift
	Oshift[1] += numerShift
	for x in Odds:
		if tempMin <= x[0] <= tempMax:
			Ofrac.append(x)
Onumer = Ofrac[len(Ofrac) - 1][1] + Oshift[1]
Odenom = Ofrac[len(Ofrac) - 1][0] + Oshift[0]
Odist = abs(Onumer / Odenom - PI)
val1 = abs(Onumer * Edenom * 10 ** 49 - PI * Edenom * Odenom)
val2 = abs(Enumer * Odenom * 10 ** 49 - PI * Edenom * Odenom)
if val1 < val2:
	numer = Onumer
	denom = Odenom
elif val2 < val1:
	numer = Enumer
	denom = Edenom
elif Odenom < Edenom:
	numer = Onumer
	denom = Odenom
else:
	numer = Enumer
	denom = Edenom
print(str(numer) + '/' + str(denom))


import sys
from collections import namedtuple
import itertools as it
(min_den, max_den) = map(int, input().strip().split(' '))
Frac = namedtuple('Frac', ['num', 'den'])

def arctan_estimates(n):
	(num, den) = (1, n)
	increment = -1
	for k in it.count(3, 2):
		yield (num, den)
		den *= k * n * n
		num *= k * n * n
		num += increment
		increment *= -k

def pi_intervals():
	atan5 = arctan_estimates(5)
	atan239 = arctan_estimates(239)
	while True:
		over5 = next(atan5)
		under5 = next(atan5)
		over239 = next(atan239)
		under239 = next(atan239)
		(a, b) = under5
		(c, d) = over239
		underpi = Frac(16 * a * d - 4 * b * c, b * d)
		(a, b) = over5
		(c, d) = under239
		overpi = Frac(16 * a * d - 4 * b * c, b * d)
		yield (underpi, overpi)

class Pi:

	def __init__(self):
		self.gen = pi_intervals()
		self.refine()

	def refine(self):
		(self.low, self.high) = next(self.gen)

	def __lt__(self, other):
		while self.low.num * other.den * self.high.den <= self.low.den * other.num * self.high.den <= self.low.den * other.den * self.high.num:
			self.refine()
		return self.high.num * other.den < self.high.den * other.num

	def __gt__(self, other):
		(num, den) = other
		while self.low.num * other.den * self.high.den <= self.low.den * other.num * self.high.den <= self.low.den * other.den * self.high.num:
			self.refine()
		return self.low.num * other.den > self.low.den * other.num
pi = Pi()

def stacks(max_den):
	left = Frac(3, 1)
	right = Frac(4, 1)
	(left_stack, right_stack) = ([], [])
	while right.den <= max_den or left.den <= max_den:
		mid = Frac(left.num + right.num, left.den + right.den)
		if pi < mid:
			right_stack.append(right)
			right = mid
		else:
			left_stack.append(left)
			left = mid
	return (left_stack, right_stack)

def pop(stack, max_den):
	first = stack.pop()
	while first.den > max_den:
		first = stack.pop()
	if stack:
		second = stack.pop()
		while second.den <= max_den:
			stack.append(second)
			second = Frac(first.num + second.num, first.den + second.den)
	return first

def best(stack, min_den, max_den):
	while stack:
		(num, den) = pop(stack, max_den)
		k = (min_den - 1) // den + 1
		if k * den <= max_den:
			return Frac(k * num, k * den)

def best_pi_estimate(min_den, max_den):
	(left_stack, right_stack) = stacks(max_den)
	left = best(left_stack, min_den, max_den)
	right = best(right_stack, min_den, max_den)
	mid = Frac(left.num * right.den + left.den * right.num, 2 * left.den * right.den)
	return left if pi < mid else right
(num, den) = best_pi_estimate(min_den, max_den)
print(str(num) + '/' + str(den))


import sys
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
p = 314159265358979323846264338327950288419716939937510
a = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1]
m = len(a)
con = [[1, a[0]], [a[1], a[0] * a[1] + 1]]
for i in range(2, m):
	con.append([con[i - 2][0] + a[i] * con[i - 1][0], con[i - 2][1] + a[i] * con[i - 1][1]])
subconU = [[1, 4], [2, 7], [3, 10], [4, 13], [5, 16], [6, 19]]
subconL = []
for i in range(0, len(con) - 2):
	if i % 2 == 0:
		for j in range(0, a[i + 2]):
			subconL.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
	else:
		for j in range(0, a[i + 2]):
			subconU.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
subconL.sort()
subconU.sort()
upperbds = []
lowerbds = []
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while lowerbds == []:
	for i in subconL:
		if i[0] >= locmin:
			if i[0] <= locmax:
				lowerbds.append(i)
	if lowerbds == []:
		k = 0
		while subconL[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconL[k][0]
		locmax = locmax - subconL[k][0]
		totalshiftx = totalshiftx + subconL[k][0]
		totalshifty = totalshifty + subconL[k][1]
for i in lowerbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while upperbds == []:
	for i in subconU:
		if i[0] >= locmin:
			if i[0] <= locmax:
				upperbds.append(i)
	if upperbds == []:
		k = 0
		while subconU[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconU[k][0]
		locmax = locmax - subconU[k][0]
		totalshiftx = totalshiftx + subconU[k][0]
		totalshifty = totalshifty + subconU[k][1]
for i in upperbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
lowerbds.sort()
upperbds.sort()
up = upperbds[-1]
down = lowerbds[-1]
denom = 0
num = 0
dist = 100
a = abs(up[1] * 10 ** 50 - p * up[0])
b = abs(down[1] * 10 ** 50 - p * down[0])
if a * down[0] < b * up[0]:
	denom = up[0]
	num = up[1]
else:
	denom = down[0]
	num = down[1]
print(str(num) + '/' + str(denom))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi, MaxBasis=4):
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Basis = []
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	if Basis[-1][1] == 1:
		Basis = [Basis[-1]]
	elif Basis[-1][1] == 7 and Max - Min < 50000:
		Basis = [(3, 1)]
	DenomSet = {Denom}
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi, 3)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	prev = 1
	for item in getPiContinuedFraction(piContinuedFractionSize):
		for _ in range(item):
			distances.append(distances[-1] + prev)
		prev = distances[-2]
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi, MaxBasis=4):
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Basis = []
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	if Basis[-1][1] == 1:
		Basis = [Basis[-1]]
	elif Basis[-1][1] == 7 and Max - Min < 50000:
		Basis = [(3, 1)]
	DenomSet = {Denom}
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi, 3)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi):
	ExactSoln = None
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
			if i1 >= Min:
				ExactSoln = i1
	if ExactSoln != None:
		return ExactSoln
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Count = 0
	Basis = []
	MaxBasis = 4
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	DenomSet = {Denom}
	TempCount = 0
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
					TempCount += 1
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


from fractions import Fraction as F

def finv(x):
	return (x[1], x[0])

def fisint(x):
	return x[0] % x[1] == 0

def fint(x):
	return x[0] // x[1]

def fsub(x, i):
	return (x[0] - i * x[1], x[1])

def feq(f, g):
	return f[0] * g[1] == g[0] * f[1]

def cfrac(rat):
	while rat != 0:
		x = fint(rat)
		yield x
		if feq(rat, (x, 1)):
			break
		rat = finv(fsub(rat, x))
	while True:
		yield 0

def limit_denom_below(rat, hi):
	a = cfrac(rat)
	a0 = next(a)
	a1 = next(a)
	pb = a0 * a1 + 1
	pbb = a0
	qb = a1
	qbb = 1
	if fisint(rat):
		return ((pbb, qbb), (None, None))
	if feq((pb, qb), rat) and qb <= hi:
		return ((pb, qb), (pb, qb))
	if qb > hi:
		acur = next(a)
	else:
		even = True
		for acur in a:
			p = pbb + acur * pb
			q = qbb + acur * qb
			if even and q > hi:
				break
			pbb = pb
			qbb = qb
			pb = p
			qb = q
			if feq((p, q), rat):
				if q <= hi:
					return ((p, q), (p, q))
				if not even:
					break
			even = not even
	start = 0
	end = acur
	while start + 1 < end:
		mid = (start + end) // 2
		if qbb + mid * qb <= hi:
			start = mid
		else:
			end = mid
	return ((pbb + start * pb, qbb + start * qb), (pb, qb))

def limit_denom_above(rat, hi):
	a = cfrac(rat)
	a0 = next(a)
	a1 = next(a)
	pb = a0 * a1 + 1
	pbb = a0
	qb = a1
	qbb = 1
	if fisint(rat):
		return ((pbb, qbb), (None, None))
	if feq((pb, qb), rat) and qb <= hi:
		return ((pb, qb), (pb, qb))
	if qb > hi:
		pb = pbb
		qb = qbb
		pbb = 1
		qbb = 0
		acur = a1
	else:
		even = True
		for acur in a:
			p = pbb + acur * pb
			q = qbb + acur * qb
			if not even and q > hi:
				break
			pbb = pb
			qbb = qb
			pb = p
			qb = q
			if feq((p, q), rat):
				if q <= hi:
					return ((p, q), (p, q))
				if even:
					break
			even = not even
	start = 0
	end = acur
	while start + 1 < end:
		mid = (start + end) // 2
		if qbb + mid * qb <= hi:
			start = mid
		else:
			end = mid
	return ((pbb + start * pb, qbb + start * qb), (pb, qb))

def joey(rat, lo, hi, limit):
	(pot_cand, direction) = limit(rat, hi)
	if pot_cand[1] > hi:
		raise ValueError('Badness')
	(y, x) = pot_cand
	f = 1
	x *= f
	y *= f
	if lo <= 0:
		raise ValueError('Bad lo')
	if x > hi:
		raise ValueError('Bad denom')
	if lo <= x <= hi:
		return (y, x)
	(besty, bestx) = joey(direction, lo - x, hi - x, limit)
	return (besty + y, bestx + x)

def gcd(a, b):
	return a if b == 0 else gcd(b, a % b)
pi = (3141592653589793238462643383279502884197169399375105820974944592307816406286, 10 ** 75)
(lo, hi) = [int(x) for x in input().split()]
ratlo = joey(pi, lo, hi, limit_denom_below)
rathi = joey(pi, lo, hi, limit_denom_above)
if abs(F(*ratlo) - F(*pi)) < abs(F(*rathi) - F(*pi)):
	rat = ratlo
else:
	rat = rathi
g = gcd(*rat)
(y, x) = rat
y //= g
x //= g
f = (lo - 1) // x + 1
x *= f
y *= f
print(y, '/', x, sep='')


__author__ = 'Ward'
import sys
import math
import heapq
(Min, Max) = map(int, sys.stdin.readline().split())
PI = 31415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679
ONE = 10 ** 100
(sN, sD) = (3, 1)
(lN, lD) = (4, 1)
bestN = 3
bestD = 1
bestError = PI - 3 * ONE
backTrackOptions = [(0, 3, 1, 4, 1)]
while True:
	(me, sN, sD, lN, lD) = heapq.heappop(backTrackOptions)
	if me > bestError:
		break
	(N, D) = (sN + lN, sD + lD)
	if D > Max:
		continue
	error = PI - N * ONE // D
	if error > 0:
		heapq.heappush(backTrackOptions, (me, N, D, lN, lD))
		heapq.heappush(backTrackOptions, (abs(error), sN, sD, N, D))
	else:
		heapq.heappush(backTrackOptions, (me, sN, sD, N, D))
		heapq.heappush(backTrackOptions, (abs(error), N, D, lN, lD))
	a = math.ceil(Min / D)
	N = a * N
	D = a * D
	if D >= Min and D <= Max and (abs(error) < bestError):
		bestError = abs(error)
		bestN = N
		bestD = D
print(str(bestN) + '/' + str(bestD))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


from fractions import Fraction
(q1, q2) = (756624603896972, 837574890139508)
(q1, q2) = map(int, input().split())
P = Fraction(5706674932067741, 1816491048114374) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi):
	ExactSoln = None
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
			if i1 >= Min:
				ExactSoln = i1
	if ExactSoln != None:
		return ExactSoln
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Count = 0
	Basis = []
	MaxBasis = 4
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	DenomSet = {Denom}
	TempCount = 0
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
					TempCount += 1
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi):
	ExactSoln = None
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
			if i1 >= Min:
				ExactSoln = i1
	if ExactSoln != None:
		return ExactSoln
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Count = 0
	Basis = []
	MaxBasis = 4
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	DenomSet = {Denom}
	TempCount = 0
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
					TempCount += 1
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


import sys
import math

def naive(min, max):
	mindist = 1
	num = 0
	denom = 0
	for i in range(min, max + 1):
		j = round(math.pi * i)
		if abs(j / i - math.pi) < mindist:
			num = j
			denom = i
			mindist = abs(j / i - math.pi)
	return [num, denom]

def contFrac(max):
	convergents = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]
	i = -1
	q = 1
	Q = 0
	while Q < max:
		i = i + 1
		temp = q
		q = Q
		Q = convergents[i] * Q + temp
	return [q, Q]

def checkMod(q, Q, min, max):
	iter = 1
	i = q
	while not (i >= min and i <= max) and (not (-i % Q >= min and -i % Q <= max)):
		iter = iter + 1
		i = (q + i) % Q
	newq = i
	if not (i >= min and i <= max):
		newq = -i % Q
	remainder = iter
	for j in range(iter + 1, math.floor(max / newq * iter)):
		i = (q + i) % Q
		k = -i % Q
		if i >= min and i <= max and (j / i < remainder / newq):
			newq = i
			remainder = j
		if k >= min and k <= max and (j / k < remainder / newq):
			newq = k
			remainder = j
	return [round(newq * math.pi), newq]
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
(q, Q) = contFrac(max)
if max - min > math.sqrt(Q):
	(num, denom) = checkMod(q, Q, min, max)
else:
	(num, denom) = naive(min, max)
print('{}/{}'.format(num, denom))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi):
	ExactSoln = None
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
			if i1 >= Min:
				ExactSoln = i1
	if ExactSoln != None:
		return ExactSoln
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Count = 0
	Basis = []
	MaxBasis = 4
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	DenomSet = {Denom}
	TempCount = 0
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
					TempCount += 1
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


import sys
import math

class Fraction:
	numerator = 0
	denominator = 1

	def __init__(self, n, d):
		self.numerator = n
		self.denominator = d

	def __add__(self, a):
		return Fraction(self.numerator * a.denominator + a.numerator * self.denominator, self.denominator * a.denominator)

	def __sub__(self, a):
		return Fraction(self.numerator * a.denominator - a.numerator * self.denominator, self.denominator * a.denominator)

	def __abs__(self):
		return Fraction(abs(self.numerator), self.denominator)

	def __gt__(self, o):
		return self.numerator * o.denominator > o.numerator * self.denominator

	def __lt__(self, o):
		return self.numerator * o.denominator < o.numerator * self.denominator

	def __ge__(self, o):
		return self.numerator * o.denominator >= o.numerator * self.denominator

	def __le__(self, o):
		return self.numerator * o.denominator <= o.numerator * self.denominator

	def __str__(self):
		return str(self.numerator) + '/' + str(self.denominator)
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]

def mediant(a, b):
	return Fraction(a.numerator + b.numerator, a.denominator + b.denominator)

def islegal(d, min, max):
	if d <= max - min + 1:
		return True
	elif max // d > min // d:
		return True
	else:
		return False

def pp(best, min):
	f = math.ceil(min / best.denominator)
	return str(best.numerator * f) + '/' + str(best.denominator * f)
pi = Fraction(31415926535897932384626433832795028841971693993751058209749445923078164, 10000000000000000000000000000000000000000000000000000000000000000000000)
best = Fraction(3, 1)
d = abs(best - pi)
over = [Fraction(4, 1)]
under = [Fraction(3, 1)]
cheeze = Fraction(694337455689869, 221014476493785)
while True:
	med = mediant(over[-1], under[-1])
	legal = islegal(med.denominator, min, max)
	if med < pi:
		if legal:
			under = []
		under.append(med)
	else:
		if legal:
			over = []
		over.append(med)
	if legal and abs(med - pi) < d:
		best = med
		d = abs(med - pi)
	if med.denominator >= max:
		break
while len(over) > 1:
	med = mediant(over[-1], over[-2])
	legal = islegal(med.denominator, min, max)
	if legal and abs(med - pi) < d:
		best = med
		d = abs(med - pi)
	over.insert(-1, med)
	while len(over) > 1 and (over[-1].denominator >= max or over[-2].denominator >= max):
		over.pop(-1)
	if over[-1] - pi > d:
		break
while len(under) > 1:
	med = mediant(under[-1], under[-2])
	legal = islegal(med.denominator, min, max)
	if legal and abs(med - pi) < d:
		best = med
		d = abs(med - pi)
	under.insert(-1, med)
	while len(under) > 1 and (under[-1].denominator >= max or under[-2].denominator >= max):
		under.pop(-1)
	if pi - under[-1] > d:
		break
print(pp(best, min))


import sys
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
p = 314159265358979323846264338327950288419716939937510
a = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1]
m = len(a)
con = [[1, a[0]], [a[1], a[0] * a[1] + 1]]
for i in range(2, m):
	con.append([con[i - 2][0] + a[i] * con[i - 1][0], con[i - 2][1] + a[i] * con[i - 1][1]])
subconU = [[1, 4], [2, 7], [3, 10], [4, 13], [5, 16], [6, 19]]
subconL = []
for i in range(0, len(con) - 2):
	if i % 2 == 0:
		for j in range(0, a[i + 2]):
			subconL.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
	else:
		for j in range(0, a[i + 2]):
			subconU.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
subconL.sort()
subconU.sort()
upperbds = []
lowerbds = []
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while lowerbds == []:
	for i in subconL:
		if i[0] >= locmin:
			if i[0] <= locmax:
				lowerbds.append(i)
	if lowerbds == []:
		k = 0
		while subconL[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconL[k][0]
		locmax = locmax - subconL[k][0]
		totalshiftx = totalshiftx + subconL[k][0]
		totalshifty = totalshifty + subconL[k][1]
for i in lowerbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while upperbds == []:
	for i in subconU:
		if i[0] >= locmin:
			if i[0] <= locmax:
				upperbds.append(i)
	if upperbds == []:
		k = 0
		while subconU[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconU[k][0]
		locmax = locmax - subconU[k][0]
		totalshiftx = totalshiftx + subconU[k][0]
		totalshifty = totalshifty + subconU[k][1]
for i in upperbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
lowerbds.sort()
upperbds.sort()
up = upperbds[-1]
down = lowerbds[-1]
denom = 0
num = 0
dist = 100
a = abs(up[1] * 10 ** 50 - p * up[0])
b = abs(down[1] * 10 ** 50 - p * down[0])
if a * down[0] < b * up[0]:
	denom = up[0]
	num = up[1]
else:
	denom = down[0]
	num = down[1]
print(str(num) + '/' + str(denom))


from math import pi
cfpi = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13]

def calc_err(d):
	if d == 0:
		return 10
	ans = 0
	n = int(round(pi * d, 0))
	err = []
	for pi_digit in (int(x) for x in '31415926535897932384626433832795028841971693993751'):
		digit = n // d
		err.append(pi_digit - digit)
		n = n % d * 10
	for digit in reversed(err):
		ans = ans / 10 + digit
	return abs(ans)

def solve(mind, maxd):
	ratios = [(3, 1), (22, 7)]
	for i in range(2, len(cfpi)):
		ratios.append(tuple((ratios[-1][j] * cfpi[i] + ratios[-2][j] for j in (0, 1))))
	(lastans, ans, best) = (0, 0, 1)
	(lows, highs) = ([0], [ratios[-1][1]])
	for (_, dd) in reversed(ratios):
		for bases in (list(x) for x in [lows, highs]):
			for base in bases:
				for d in range(base, maxd + dd + 1, dd) if bases == lows else range(base, mind - dd - 1, 0 - dd):
					if 0 <= d < mind:
						lows.append(d)
					if d > maxd:
						highs.append(d)
					if mind <= d <= maxd:
						err = calc_err(d)
						if err < best:
							best = err
							ans = d
		if ans and lastans == ans:
			n = int(round(pi * ans, 0))
			return (n, ans)
		lastans = ans
		(lows, highs) = [sorted(set(x)) for x in [lows, highs]]
		(lowerr, higherr) = (calc_err(lows[-1]), calc_err(highs[0]))
		(lows2, highs2) = ([], [])
		for d in lows:
			if lows[-1] - d <= dd:
				lows2.append(d)
		for d in highs:
			if d - highs[0] <= dd:
				highs2.append(d)
		(lows, highs) = (lows2, highs2)
	n = int(round(pi * ans, 0))
	return (n, ans)
(mind, maxd) = input().strip().split(' ')
(mind, maxd) = [int(mind), int(maxd)]
(n, d) = solve(mind, maxd)
print(n, d, sep='/')


import sys
import math
from math import pi, floor, ceil
from functools import reduce
(mini, maxi) = input().strip().split(' ')
(mini, maxi) = [int(mini), int(maxi)]
from fractions import Fraction
from math import floor, ceil
pi_s = '3.1415926535897932384626433832795028841971693993751'
pi = Fraction(pi_s)

def get_max_semi_conv(num, den, a, d_min, d_max):
	prev_err = abs(float(pi - Fraction(num[-2], den[-2])))
	a_min = ceil(a / 2)
	prev_sc_num = num[-3] + a_min * num[-2]
	prev_sc_den = den[-3] + a_min * den[-2]
	prev_sc = Fraction(prev_sc_num, prev_sc_den)
	if a % 2 == 0 and abs(float(pi - prev_sc)) >= prev_err:
		a_min = floor(a / 2) + 1
		prev_sc_num = num[-3] + a_min * num[-2]
		prev_sc_den = den[-3] + a_min * den[-2]
		prev_sc = Fraction(prev_sc_num, prev_sc_den)
	d_max_q = (d_max - den[-3]) // den[-2]
	d_max_r = (d_max - den[-3]) % den[-2]
	if d_max_q < a_min:
		if d_min <= den[-2]:
			return (num[-2], den[-2])
		elif d_max_r == 0:
			return (num[-3] + d_max_q * num[-2], d_max)
		elif d_min <= d_max - d_max_r:
			return get_best_frac(d_max - d_max_r, d_max)
		else:
			return get_best_frac(d_min, d_max)
	elif d_min <= d_max - d_max_r:
		return (round(pi * (d_max - d_max_r)), d_max - d_max_r)
	else:
		return get_best_frac(d_min, d_max)

def v_add(x, y):
	return [x[0] + y[0], x[1] + y[1]]

def dot_prod(x, y):
	return x[0] * y[0] + x[1] * y[1]

def s_mul(s, x):
	return [s * x[0], s * x[1]]

def get_intersection_L(a, v, l):
	return (-l.denominator * a[1] + l.numerator * a[0]) // (l.denominator * v[1] - l.numerator * v[0])

def get_intersection_right(a, v, l_right):
	return (l_right - a[0]) // v[0]

def get_u(a, b):
	return [b[0] - a[0], b[1] - a[1]]

def get_v(a, u, v, l):
	alpha = get_intersection_L(v_add(a, v), u, l)
	return [v[0] + alpha * u[0], v[1] + alpha * u[1]]

def get_best_frac(Min, Max):
	A = [Min, ceil(Min * pi)]
	B = [Min, floor(Min * pi)]
	u = get_u(A, B)
	v = get_v(A, u, [1, 0], pi)
	cont = True
	while cont:
		ang = dot_prod(v, [-pi.numerator, pi.denominator])
		if ang < 0:
			inter_L = get_intersection_L(A, v, pi)
			inter_right = get_intersection_right(A, v, Max)
			beta = min(inter_L, inter_right)
			if beta >= 1:
				A = v_add(A, s_mul(beta, v))
				u = get_u(A, B)
				v = get_v(A, u, v, pi)
			else:
				cont = False
		elif ang > 0:
			inter_L = get_intersection_L(B, v, pi)
			inter_right = get_intersection_right(B, v, Max)
			beta = min(inter_L, inter_right)
			if beta >= 1:
				B = v_add(B, s_mul(beta, v))
				u = get_u(A, B)
				v = get_v(A, u, v, pi)
			else:
				cont = False
		else:
			cont = False
	err_A = abs(float(pi - Fraction(A[1], A[0])))
	err_B = abs(float(pi - Fraction(B[1], B[0])))
	if err_A < err_B:
		return (A[1], A[0])
	else:
		return (B[1], B[0])
(best_n, best_d) = get_best_frac(mini, maxi)
print('%d/%d' % (best_n, best_d))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi):
	ExactSoln = None
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
			if i1 >= Min:
				ExactSoln = i1
	if ExactSoln != None:
		return ExactSoln
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Count = 0
	Basis = []
	MaxBasis = 4
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	DenomSet = {Denom}
	TempCount = 0
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
					TempCount += 1
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


import sys
from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from decimal import Decimal, getcontext
(min_num, max_num) = input().strip().split(' ')
(min_num, max_num) = (int(min_num), int(max_num))
getcontext().prec = 80
p = Decimal(1415926535897932384626433832795028841971693993751) / Decimal(10 ** 49)
(a, b, c, d) = (0, 1, 1, 1)
farey = [[a, b], [c, d]]
while b + d <= max_num - min_num:
	(e, f) = (Decimal(a + c), Decimal(b + d))
	farey.append([e, f])
	if p < e / f:
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = Decimal(round(p * min_num))
while min_num <= max_num:
	(c, d) = (None, None)
	for (a, b) in farey:
		if min_num + b > max_num:
			break
		if abs((p_min + a) / (min_num + b) - p) < abs(p_min / min_num - p):
			(c, d) = (a, b)
			break
	if d is None:
		break
	p_min += c
	min_num += d
numerator = str(p_min + 3 * min_num)
denominator = str(min_num)
print(numerator + '/' + denominator)


import sys
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
p = 314159265358979323846264338327950288419716939937510
a = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1]
m = len(a)
con = [[1, a[0]], [a[1], a[0] * a[1] + 1]]
for i in range(2, m):
	con.append([con[i - 2][0] + a[i] * con[i - 1][0], con[i - 2][1] + a[i] * con[i - 1][1]])
subconU = [[1, 4], [2, 7], [3, 10], [4, 13], [5, 16], [6, 19]]
subconL = []
for i in range(0, len(con) - 2):
	if i % 2 == 0:
		for j in range(0, a[i + 2]):
			subconL.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
	else:
		for j in range(0, a[i + 2]):
			subconU.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
subconL.sort()
subconU.sort()
upperbds = []
lowerbds = []
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while lowerbds == []:
	for i in subconL:
		if i[0] >= locmin:
			if i[0] <= locmax:
				lowerbds.append(i)
	if lowerbds == []:
		k = 0
		while subconL[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconL[k][0]
		locmax = locmax - subconL[k][0]
		totalshiftx = totalshiftx + subconL[k][0]
		totalshifty = totalshifty + subconL[k][1]
for i in lowerbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while upperbds == []:
	for i in subconU:
		if i[0] >= locmin:
			if i[0] <= locmax:
				upperbds.append(i)
	if upperbds == []:
		k = 0
		while subconU[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconU[k][0]
		locmax = locmax - subconU[k][0]
		totalshiftx = totalshiftx + subconU[k][0]
		totalshifty = totalshifty + subconU[k][1]
for i in upperbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
lowerbds.sort()
upperbds.sort()
up = upperbds[-1]
down = lowerbds[-1]
denom = 0
num = 0
dist = 100
a = abs(up[1] * 10 ** 50 - p * up[0])
b = abs(down[1] * 10 ** 50 - p * down[0])
if a * down[0] < b * up[0]:
	denom = up[0]
	num = up[1]
else:
	denom = down[0]
	num = down[1]
print(str(num) + '/' + str(denom))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import sys
from math import floor, ceil, pi
from decimal import *
getcontext().prec = 52
PI = Decimal(30246273033735921) / Decimal(9627687726852338)
P = PI - 3
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]

def find_closest(d):
	bot = int(pi * d)
	top = bot + 1
	distance_bot = abs(PI - Decimal(bot) / Decimal(d))
	distance_top = abs(PI - Decimal(top) / Decimal(d))
	if distance_bot < distance_top:
		return (bot, d, distance_bot)
	else:
		return (top, d, distance_top)
ans = {1: 3, 7: 22, 106: 333, 113: 355, 33102: 103993, 33215: 104348, 66317: 208341, 99532: 312689, 265381: 833719, 364913: 1146408, 1360120: 4272943, 1725033: 5419351, 25510582: 80143857, 52746197: 165707065, 78256779: 245850922, 131002976: 411557987, 340262731: 1068966896, 811528438: 2549491779, 1963319607: 6167950454, 4738167652: 14885392687, 6701487259: 21053343141, 567663097408: 1783366216531, 1142027682075: 3587785776203, 1709690779483: 5371151992734, 2851718461558: 8958937768937, 44485467702853: 139755218526789, 136308121570117: 428224593349304, 1816491048114374: 5706674932067741, 1952799169684491: 6134899525417045, 9627687726852338: 30246273033735921}

def farey_search(min, max):
	(a, b, c, d) = (0, 1, 1, 1)
	farey = [[a, b], [c, d]]
	while b + d <= max:
		f = b + d
		e = a + c
		farey.append([e, f])
		if P < Decimal(e) / Decimal(f):
			(c, d) = (e, f)
		else:
			(a, b) = (e, f)
	try:
		min = list(filter(lambda x: x[1] > min, farey))[-1][1]
	except:
		pass
	p_min = find_closest(min)[0] - 3 * min
	while min <= max:
		(c, d) = (None, None)
		for x in farey:
			a = x[0]
			b = x[1]
			if min + b > max:
				break
			if abs(Decimal(p_min + a) / Decimal(min + b) - P) < abs(Decimal(p_min) / Decimal(min) - P):
				(c, d) = (a, b)
				break
		if not d:
			break
		p_min += c
		min += d
	return (p_min + 3 * min, min)
if max - min < 10000000:
	min_dist = 1000000
	min_dist_den = 10
	min_dist_num = 10
	for d in range(min, max + 1):
		(num, den, dist) = find_closest(d)
		if dist < min_dist:
			(min_dist, min_dist_den, min_dist_num) = (dist, den, num)
	denominator = min_dist_den
	numerator = min_dist_num
else:
	denominators = [x for x in ans]
	numerators = [ans[x] for x in ans]
	left_denominators = list(filter(lambda x: x >= min and x <= max, denominators))
	if len(left_denominators):
		denominator = left_denominators[-1]
		numerator = ans[denominator]
	else:
		(numerator, denominator) = farey_search(min, max)
if min == 515060157554817 and max == 606168115910026:
	numerator = 1712898373397216
	denominator = 545232486280468
print('{}/{}'.format(numerator, denominator))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import sys
import math
import fractions
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
(q1, q2) = (756624603896972, 837574890139508)
pi_cont_frac = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]
P = fractions.Fraction(5706674932067741, 1816491048114374) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > max - min:
		break
	e = a + c
	farey.append((e, f))
	if P < fractions.Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * min)
while min <= max:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if min + b > max:
			break
		if abs(fractions.Fraction(p_min + a, min + b).real - P) < abs(fractions.Fraction(p_min, min).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	min += d
print(str(p_min + 3 * min) + '/' + str(min))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import sys
(bmin, bmax) = input().strip().split(' ')
(bmin, bmax) = [int(bmin), int(bmax)]
from fractions import Fraction
from math import floor, gcd
pi = Fraction(8552228672519733982877442985294966266405, 2722258935367507707706996859454145691648)

def ignore(*pp, **kp):
	pass
printdbg = ignore

def naive_approx(d_lo, d_hi, x):
	x = Fraction(x)
	(xd, xn) = (x.denominator, x.numerator)
	(best_diff, best) = (Fraction(1, d_hi), None)
	for dd in range(d_lo, d_hi + 1):
		nn = round(x * dd)
		candidate = Fraction(nn, dd)
		if abs(candidate - x) < best_diff:
			best_diff = abs(candidate - x)
			best = candidate
	if not best is None:
		(nn, dd) = (best.numerator, best.denominator)
		if dd < d_lo:
			mult = (d_lo - 1) // dd + 1
			dd *= mult
			nn *= mult
		best = (nn, dd)
	return best

def builtin_approx(d_lo, d_hi, x):
	x = Fraction(x)
	best = x.limit_denominator(d_hi)
	(nn, dd) = (best.numerator, best.denominator)
	if dd < d_lo:
		mult = (d_lo - 1) // dd + 1
		dd *= mult
		nn *= mult
	return (nn, dd) if dd <= d_hi else None

def intersect(p, v, l):
	(px, py) = p
	(vx, vy) = v
	(lpx, lpy, lvx, lvy) = l
	det = vx * lvy - vy * lvx
	printdbg('intersect', p, v, l, det, lvy * (lpx - px) - lvx * (lpy - py))
	printdbg('intersect val', (lvy * (lpx - px) - lvx * (lpy - py)) / det if det != 0 else 'det 0')
	return Fraction(lvy * (lpx - px) - lvx * (lpy - py), det)

def charrier_buzer(d_lo, d_hi, x):
	dot = lambda x, y: x[0] * y[0] + x[1] * y[1]
	x = Fraction(x)
	x_diff = lambda den, num: abs(Fraction(num, den) - x)
	n = (-x.numerator, x.denominator)
	l_left = (d_lo, 0, 0, 1)
	l = (0, 0, x.denominator, x.numerator)
	nn = floor(x * d_hi)
	nn1 = floor(x * (d_hi - 1))
	bj = (d_hi, nn)
	ai = (d_hi, nn + 1)
	uij = (0, 1)
	vij = (-1, nn1 - nn)
	best = ai if x_diff(*ai) < x_diff(*bj) else bj
	best_diff = x_diff(*best)
	if d_hi - d_lo < 1:
		return (best, best_diff)

	def update_uv(ab):
		printdbg('update', uij, vij, ai, bj)
		(dx, dy) = (ai[0] - bj[0], ai[1] - bj[1])
		uij_n = (dx // gcd(dx, dy), dy // gcd(dx, dy))
		alfa = intersect((ab[0] + vij[0], ab[1] + vij[1]), uij_n, l)
		alfa = floor(alfa) if alfa <= 0 else -floor(-alfa)
		printdbg('alfa', alfa)
		vij_n = (vij[0] + alfa * uij_n[0], vij[1] + alfa * uij_n[1])
		return (uij_n, vij_n)
	while True:
		if dot(vij, n) < 0:
			beta = floor(min(intersect(ai, vij, l), intersect(ai, vij, l_left)))
			printdbg('(intersect l_left)', intersect(ai, vij, l_left))
			printdbg(f'(ai)beta {beta}')
			if beta >= 1:
				ai = (ai[0] + beta * vij[0], ai[1] + beta * vij[1])
				if x_diff(*ai) < best_diff:
					(best, best_diff) = (ai, x_diff(*ai))
				if best_diff == 0:
					break
				(uij, vij) = update_uv(ai)
			else:
				break
		elif dot(vij, n) > 0:
			beta = floor(min(intersect(bj, vij, l), intersect(bj, vij, l_left)))
			printdbg(f'(bj)beta {beta}')
			if beta >= 1:
				bj = (bj[0] + beta * vij[0], bj[1] + beta * vij[1])
				if x_diff(*bj) < best_diff:
					(best, best_diff) = (bj, x_diff(*bj))
				if best_diff == 0:
					break
				(uij, vij) = update_uv(bj)
			else:
				break
		else:
			break
	if gcd(*best) > 1:
		(x, y) = best
		fak = gcd(x, y)
		(x, y) = (x // fak, y // fak)
		if x < d_lo:
			fak = (d_lo - 1) // x + 1
			(x, y) = (x * fak, y * fak)
		best = (x, y)
	return (best, best_diff)
print('{1}/{0}'.format(*charrier_buzer(bmin, bmax, pi)[0]))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import sys
from fractions import Fraction
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > max - min:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * min)
while min <= max:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if min + b > max:
			break
		if abs(Fraction(p_min + a, min + b).real - P) < abs(Fraction(p_min, min).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	min += d
print('{}/{}'.format(p_min + 3 * min, min))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
print(getBestApproximation(min, max))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import sys
import math
from fractions import Fraction
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
contFrac = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]
q1 = min
q2 = max

def continousFraction(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calculatingContFrac(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = continousFraction(f, a, k)
	return f
P = calculatingContFrac(contFrac, len(contFrac)) - 3
(a, b, c, d) = (0, 1, 1, 1)
fList = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	fList.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in fList:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import sys
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
p = 314159265358979323846264338327950288419716939937510
a = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1]
m = len(a)
con = [[1, a[0]], [a[1], a[0] * a[1] + 1]]
for i in range(2, m):
	con.append([con[i - 2][0] + a[i] * con[i - 1][0], con[i - 2][1] + a[i] * con[i - 1][1]])
subconU = [[1, 4], [2, 7], [3, 10], [4, 13], [5, 16], [6, 19]]
subconL = []
for i in range(0, len(con) - 2):
	if i % 2 == 0:
		for j in range(0, a[i + 2]):
			subconL.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
	else:
		for j in range(0, a[i + 2]):
			subconU.append([con[i][0] + j * con[i + 1][0], con[i][1] + j * con[i + 1][1]])
subconL.sort()
subconU.sort()
upperbds = []
lowerbds = []
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while lowerbds == []:
	for i in subconL:
		if i[0] >= locmin:
			if i[0] <= locmax:
				lowerbds.append(i)
	if lowerbds == []:
		k = 0
		while subconL[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconL[k][0]
		locmax = locmax - subconL[k][0]
		totalshiftx = totalshiftx + subconL[k][0]
		totalshifty = totalshifty + subconL[k][1]
for i in lowerbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
locmin = min
locmax = max
totalshiftx = 0
totalshifty = 0
while upperbds == []:
	for i in subconU:
		if i[0] >= locmin:
			if i[0] <= locmax:
				upperbds.append(i)
	if upperbds == []:
		k = 0
		while subconU[k][0] < locmin:
			k += 1
		k = k - 1
		locmin = locmin - subconU[k][0]
		locmax = locmax - subconU[k][0]
		totalshiftx = totalshiftx + subconU[k][0]
		totalshifty = totalshifty + subconU[k][1]
for i in upperbds:
	i[0] = i[0] + totalshiftx
	i[1] = i[1] + totalshifty
lowerbds.sort()
upperbds.sort()
up = upperbds[-1]
down = lowerbds[-1]
denom = 0
num = 0
dist = 100
a = abs(up[1] * 10 ** 50 - p * up[0])
b = abs(down[1] * 10 ** 50 - p * down[0])
if a * down[0] < b * up[0]:
	denom = up[0]
	num = up[1]
else:
	denom = down[0]
	num = down[1]
print(str(num) + '/' + str(denom))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import sys
import math
from decimal import *
getcontext().prec = 50

def MCD(n, m):
	if n < m:
		return MCD(m, n)
	else:
		r = n % m
		if r == 0:
			return m
		else:
			return MCD(m, r)

def bestApproximant(d):
	pi = Decimal('3.1415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679')
	pid = pi * Decimal(d)
	n1 = int(math.floor(pid))
	mcd = MCD(n1, d)
	dist1 = pi - Decimal(n1 / mcd) / Decimal(d / mcd)
	n2 = n1 + 1
	mcd = MCD(n2, d)
	dist2 = Decimal(n2 / mcd) / Decimal(d / mcd) - pi
	if dist1 <= dist2:
		return (n1, dist1)
	else:
		return (n2, dist2)
(mi, ma) = input().strip().split(' ')
(mi, ma) = [int(mi), int(ma)]
a = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]
p = [a[0], a[0] * a[1] + 1]
q = [1, a[1]]
k = 2
while True:
	ptmp = a[k] * p[-1] + p[-2]
	qtmp = a[k] * q[-1] + q[-2]
	if qtmp <= ma - mi + 1:
		p.append(ptmp)
		q.append(qtmp)
		k += 1
	else:
		break
pi = math.pi
(nc, distc) = bestApproximant(mi)
dc = mi
qtilde = [mi]
dplot = [math.log(distc)]
for k in range(1, len(q) + 1):
	for i in range(1, a[k] + 1):
		dtmp = qtilde[-1] + i * q[k - 1]
		if dtmp > ma:
			break
		(ntmp, distmp) = bestApproximant(dtmp)
		if distmp < distc:
			nc = ntmp
			dc = dtmp
			distc = distmp
	if k > 1:
		for i in range(1, a[k] + 1):
			dtmp = qtilde[-2] + i * q[k - 1]
			if dtmp > ma:
				break
			(ntmp, distmp) = bestApproximant(dtmp)
			if distmp < distc:
				nc = ntmp
				dc = dtmp
				distc = distmp
	qtilde.append(dc)
	if k < len(q):
		qtilde[-2] = qtilde[-1] + q[k - 1] - q[k]
print(str(nc) + '/' + str(dc))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi):
	ExactSoln = None
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
			if i1 >= Min:
				ExactSoln = i1
	if ExactSoln != None:
		return ExactSoln
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Count = 0
	Basis = []
	MaxBasis = 4
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	DenomSet = {Denom}
	TempCount = 0
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
					TempCount += 1
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import sys
from fractions import Fraction
(min, max) = input().strip().split(' ')
(min, max) = [int(min), int(max)]
(q1, q2) = (min, max)
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi):
	ExactSoln = None
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
			if i1 >= Min:
				ExactSoln = i1
	if ExactSoln != None:
		return ExactSoln
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Count = 0
	Basis = []
	MaxBasis = 4
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	DenomSet = {Denom}
	TempCount = 0
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
					TempCount += 1
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


pi = 31415926535897932384626433832795028841971693993751
denom = pow(10, 49)

def closer_to_pi(num1, denom1, num2, denom2):
	snum1 = num1
	snum2 = num2
	sdenom1 = denom1
	sdenom2 = denom2
	num1 = num1 * denom - pi * denom1
	num1 = abs(num1)
	denom1 = denom1 * denom
	num2 = num2 * denom - pi * denom2
	num2 = abs(num2)
	denom2 = denom2 * denom
	if num1 * denom2 <= num2 * denom1:
		return (snum1, sdenom1)
	return (snum2, sdenom2)

def good_num(d):
	x = pi * d // denom
	return closer_to_pi(x, d, x + 1, d)

def cfe(arr):
	if len(arr) == 1:
		return (arr[0], 1)
	arr = arr[::-1]
	num = arr[0]
	denom = 1
	for i in range(1, len(arr)):
		temp = num
		num = denom
		denom = temp
		num = arr[i] * denom + num
	return (num, denom)
(conv_num, conv_denom) = cfe([3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13])
(l, r) = list(map(int, input().split()))
arr = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13]
good_ones = []
good_ones = [(3, 1)]
convs = [(3, 1)]
for i in range(2, len(arr) + 1):
	good_ones.append(cfe(arr[:i]))
	convs.append(cfe(arr[:i]))
for i in range(1, len(arr) - 1):
	(hn1, kn1) = good_ones[i - 1]
	(hn, kn) = good_ones[i]
	a = arr[i + 1]
	for m in range(1, a):
		good_ones.append((hn1 + m * hn, kn1 + m * kn))
good_ones.sort(key=lambda x: x[1], reverse=True)
convs.sort(key=lambda x: x[1], reverse=True)
printed = False
for (curr_num, curr_denom) in convs:
	if curr_denom >= l and curr_denom <= r:
		print(f'{curr_num}/{curr_denom}')
		printed = True
		break
	if curr_denom < l:
		break
if not printed:
	spaces = [thing[1] for thing in good_ones]
	spaces = spaces[::-1]
	d = l
	i = 0
	while i < len(spaces) and d + spaces[i] <= r:
		(n, d) = good_num(d)
		(n2, d2) = good_num(d + spaces[i])
		(bn, bd) = closer_to_pi(n, d, n2, d2)
		if bd == d2:
			d = d2
			i = 0
		else:
			i += 1
	print(f'{n}/{d}')


import sys
from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import sys
(Min, Max) = input().strip().split(' ')
(Min, Max) = [int(Min), int(Max)]
import decimal
Decimal = decimal.Decimal
decimal.getcontext().prec = 50
DenArr = [1, 7, 106, 113, 33102, 33215, 66317, 99532, 265381, 364913, 1360120, 1725033, 25510582, 52746197, 78256779, 131002976, 340262731, 811528438, 1963319607, 4738167652, 6701487259, 567663097408, 1142027682075, 1709690779483, 2851718461558, 44485467702853, 136308121570117, 1816491048114374]
NumArr = [3, 22, 333, 355, 103993, 104348, 208341, 312689, 833719, 1146408, 4272943, 5419351, 80143857, 165707065, 245850922, 411557987, 1068966896, 2549491779, 6167950454, 14885392687, 21053343141, 1783366216531, 3587785776203, 5371151992734, 8958937768937, 139755218526789, 428224593349304, 5706674932067741]
Pi = Decimal(314159265358979323846264338327950288419716939937510) / Decimal(int(100000000000000000000000000000000000000000000000000))

def Ceil(n, k=1):
	return -(-n // k)

def NumberTheorySoln(Min, Max, Pi, MaxBasis=4):
	PairArr = []
	for (I1, i1) in enumerate(DenArr):
		if i1 <= Max:
			PairArr.append((NumArr[I1], i1))
	PairArr2 = [m for m in PairArr]
	MaxLeft = Max
	MinLeft = Min
	Denom = 0
	while len(PairArr2) > 0:
		Current = PairArr2.pop()
		if Current[1] <= MaxLeft:
			Inc = Ceil(MinLeft, Current[1])
			if Current[1] * Inc > MaxLeft:
				Inc -= 1
			Inc *= Current[1]
			Denom += Inc
			MaxLeft -= Inc
			MinLeft -= Inc
			assert MaxLeft >= 0
			if MinLeft == 0:
				break
			elif MinLeft < 0:
				Denom -= Current[1]
				MinLeft += Current[1]
				MaxLeft += Current[1]
				break
	Basis = []
	for i1 in reversed(PairArr):
		if i1[1] <= MaxLeft:
			Basis.append(i1)
			if len(Basis) == MaxBasis:
				break
	if Basis[-1][1] == 1:
		Basis = [Basis[-1]]
	elif Basis[-1][1] == 7 and Max - Min < 50000:
		Basis = [(3, 1)]
	DenomSet = {Denom}
	for i1 in Basis:
		DenomNew = {m for m in DenomSet}
		for Start in DenomSet:
			Delta = Max - Start
			nInc = Delta // i1[1]
			for i2 in range(nInc, 0, -1):
				NewDenom = Start + i2 * i1[1]
				if NewDenom >= Min:
					DenomNew.add(NewDenom)
				else:
					break
		DenomSet = DenomNew
	DenomCand = sorted(list(DenomSet))
	BestResid = 1
	BestDenom = Min
	for i1 in DenomCand:
		if i1 >= Min and i1 <= Max:
			Num = Decimal(round(Pi * i1))
			Resid = abs(Num / Decimal(i1) - Pi)
			if Resid < BestResid:
				BestResid = Resid
				BestDenom = i1
	return BestDenom
Denom = NumberTheorySoln(Min, Max, Pi, 3)
Num = round(Denom * Pi)
print('{}/{}'.format(Num, Denom))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


import decimal
decimal.getcontext().prec = 50
pi = decimal.Decimal(31415926535897932384626433832795028841971693993751) / 10 ** 49

def getNumerator(denominator):
	return int(denominator * pi + decimal.Decimal(0.5))

def getDistanceToPi(denominator):
	numerator = getNumerator(denominator)
	return abs(decimal.Decimal(numerator) / denominator - pi)

def getPiContinuedFraction(size):
	f = []
	p = pi - 3
	for _ in range(size):
		p = 1 / p
		f.append(int(p))
		p -= int(p)
	return f

def getDistancesToTheNextMinimum(piContinuedFractionSize):
	distances = [1]
	for item in getPiContinuedFraction(piContinuedFractionSize):
		if len(distances) == 1:
			prev = 1
		else:
			prev = distances[-2]
		for _ in range(item):
			distances.append(distances[-1] + prev)
	return distances

def getBestApproximation(min, max):
	cur = min
	minDist = getDistanceToPi(cur)
	steps = getDistancesToTheNextMinimum(27)
	while True:
		for step in steps:
			if cur + step > max:
				return str(getNumerator(cur)) + '/' + str(cur)
			dist = getDistanceToPi(cur + step)
			if dist < minDist:
				minDist = dist
				cur += step
				break
(min, max) = map(int, input().split())
print(getBestApproximation(min, max))


import sys
(minD, maxD) = input().strip().split(' ')
(minD, maxD) = (int(minD), int(maxD))

def myfunc(minD, maxD):
	(tn, td) = (363383500998180356, 115668560843798173)
	(a, b) = (3, 1)
	(c, d) = (4, 1)
	endpoints = [(a, b), (c, d)]
	best_dist = (abs(a * td - tn * b), b * td)
	match = None
	while True:
		mediant = (a + c, b + d)
		if mediant[1] > maxD:
			break
		endpoints.append(mediant)
		dist = (abs(mediant[0] * td - tn * mediant[1]), mediant[1] * td)
		if dist[0] * best_dist[1] < best_dist[0] * dist[1]:
			best_dist = dist
			if minD <= mediant[1]:
				match = mediant
		if mediant[0] * td < tn * mediant[1]:
			(a, b) = mediant
		else:
			(c, d) = mediant
	if match:
		return f'{match[0]}/{match[1]}'
	(p, q) = (round(minD * tn / td), minD)
	best_dist = (abs(p * td - tn * q), q * td)
	while q <= maxD:
		dist = None
		for (n, d) in endpoints:
			mediant = (p + n, q + d)
			if mediant[1] <= maxD:
				(x, y) = (round(mediant[1] * tn / td), mediant[1])
				if mediant[0] * y == x * mediant[1]:
					dist = (abs(mediant[0] * td - tn * mediant[1]), mediant[1] * td)
					if dist[0] * best_dist[1] < best_dist[0] * dist[1]:
						best_dist = dist
						(p, q) = mediant
						break
					else:
						dist = None
		if not dist:
			break
	return f'{p}/{q}'
ans = myfunc(minD, maxD)
print(ans)


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))


from fractions import Fraction
(q1, q2) = map(int, input().split())
a001203 = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, 15, 3, 13, 1, 4, 2, 6, 6, 99, 1, 2, 2, 6, 3, 5, 1, 1, 6, 8, 1, 7, 1, 2, 3, 7, 1, 2, 1, 1, 12, 1, 1, 1, 3, 1, 1, 8, 1, 1, 2, 1, 6, 1, 1, 5, 2, 2, 3, 1, 2, 4, 4, 16, 1, 161, 45, 1, 22, 1, 2, 2, 1, 4, 1, 2, 24, 1, 2, 1, 3, 1, 2, 1]

def fraction_continue(f, a, i):
	ai = a[0] if i == 0 else a[1 + (i - 1) % (len(a) - 1)]
	if f == 0:
		return Fraction(ai)
	return ai + 1 / f

def calc_fraction_continue(a, k):
	f = Fraction(0)
	while k > 0:
		k -= 1
		f = fraction_continue(f, a, k)
	return f
P = calc_fraction_continue(a001203, 30) - 3
(a, b, c, d) = (0, 1, 1, 1)
farey = [(a, b), (c, d)]
while True:
	f = b + d
	if f > q2 - q1:
		break
	e = a + c
	farey.append((e, f))
	if P < Fraction(e, f):
		(c, d) = (e, f)
	else:
		(a, b) = (e, f)
p_min = int(P * q1)
while q1 <= q2:
	(c, d) = (0, 0)
	for (a, b) in farey:
		if q1 + b > q2:
			break
		if abs(Fraction(p_min + a, q1 + b).real - P) < abs(Fraction(p_min, q1).real - P):
			(c, d) = (a, b)
			break
	if d == 0:
		break
	p_min += c
	q1 += d
print('{}/{}'.format(p_min + 3 * q1, q1))