Barney is standing in a bar and starring at a pretty girl. He wants to shoot her with his heart arrow but he needs to know the distance between him and the girl to make his shot accurate. [Image] 

Barney asked the bar tender Carl about this distance value, but Carl was so busy talking to the customers so he wrote the distance value (it's a real number) on a napkin. The problem is that he wrote it in scientific notation. The scientific notation of some real number x is the notation of form AeB, where A is a real number and B is an integer and x = A × 10^{B} is true. In our case A is between 0 and 9 and B is non-negative.

Barney doesn't know anything about scientific notation (as well as anything scientific at all). So he asked you to tell him the distance value in usual decimal representation with minimal number of digits after the decimal point (and no decimal point if it is an integer). See the output format for better understanding.


-----Input-----

The first and only line of input contains a single string of form a.deb where a, d and b are integers and e is usual character 'e' (0 ≤ a ≤ 9, 0 ≤ d < 10^100, 0 ≤ b ≤ 100) — the scientific notation of the desired distance value.

a and b contain no leading zeros and d contains no trailing zeros (but may be equal to 0). Also, b can not be non-zero if a is zero.


-----Output-----

Print the only real number x (the desired distance value) in the only line in its decimal notation. 

Thus if x is an integer, print it's integer value without decimal part and decimal point and without leading zeroes. 

Otherwise print x in a form of p.q such that p is an integer that have no leading zeroes (but may be equal to zero), and q is an integer that have no trailing zeroes (and may not be equal to zero).


-----Examples-----
Input
8.549e2

Output
854.9

Input
8.549e3

Output
8549

Input
0.33e0

Output
0.33

Source: codeforces | Difficulty: MEDIUM
Tags: Mathematics

String algorithms

Implementation

Complete search


Solutions:
import sys
string = input()
dot = string.index('.')
a = string[0:dot]
d = string[dot + 1:string.index('e')]
b = int(string[string.index('e') + 1:len(string)])
if a == '0' and int(d) == 0 and (b == 0):
	res = 0
elif a != '0' and int(d) == 0 and (b == 0):
	res = a
elif len(d) > b and a != '0':
	res = a + d[0:b] + '.' + d[b:]
elif len(d) == b and a != '0':
	res = a + d
elif b > len(d) and a != '0':
	res = a + d + '0' * (b - len(d))
elif b == 0 and a == '0':
	res = string[0:string.index('e')]
elif b > 0 and a == '0':
	if b > len(d):
		res = d + '0' * abs(b - len(d))
	elif b < len(d):
		res = d[0:b] + '.' + d[b:]
	elif b == len(d):
		res = d
print(res)


def main():
	string = input('')
	list = string.split('e')
	b = int(list[1])
	L = len(list[0]) - 2
	list1 = str(list[0]).split('.')
	final = ''.join(list1)
	if L > b:
		position = 2 + b
		ans = ''
		ans1 = final[0:position - 1]
		ans2 = final[position - 1:]
		ans = ans1 + '.' + ans2
	elif L == b:
		ans = ''
		ans = final
	elif L < b:
		ans1 = ''
		ans = ''
		for i in range(b - L):
			ans1 = ans1 + '0'
		ans = final + ans1
	if ans[1] == '.' and ans[2] == '0' and (len(ans) == 3):
		print(int(eval(ans)))
	elif eval(ans) == int(eval(ans)):
		print(ans)
	else:
		listans = ans.split('.')
		finalans1 = ''
		finalans2 = ''
		finalans1 = str(int(listans[0]))
		finalans2 = str(listans[1])
		finalans = finalans1 + '.' + finalans2
		print(finalans)
main()


from math import *
n = input().split('e')
po = int(n[1])
res = n[0][0]
w = 2
while po:
	if w < len(n[0]):
		res += n[0][w]
	else:
		res += '0'
	po -= 1
	w += 1
if w < len(n[0]) and n[0][w:] != '0':
	res += '.'
	res += n[0][w:]
print(res)


(a, b) = input().split('e')
a = a[:1] + a[2:]
b = int(b)
a += '0' * 200
a = a[:b + 1] + '.' + a[b + 1:]
while a[-1] == '0':
	a = a[:-1]
if a[-1] == '.':
	a = a[:-1]
print(a)


s = input()
l1 = s.find('.')
l2 = s.find('e')
a = s[0:l1] + s[l1 + 1:l2]
b = int(s[l2 + 1:len(s)])
for i in range(100):
	a += '0'
a = a[0:l1 + b] + '.' + a[l1 + b:len(a)]
while a[-1] == '0':
	a = a[0:-1]
if a[-1] == '.':
	a = a[0:-1]
print(a)


(a, b) = input().split('e')
b = int(b)
pos = a.find('.') + b
a = ''.join(a.split('.'))
a = list(a)
while len(a) < pos:
	a.append('0')
a = ''.join(a[:pos]) + '.' + ''.join(a[pos:])
if len(a) == pos + 1:
	a = a[:-1]
elif len(a) > 2 and a[-2:] == '.0':
	a = a[:-2]
print(a)


s = input().split('.')
s[1] = s[1].split('e')
s = [s[0]] + s[1]
a = int(s[0])
d = int(s[1])
b = int(s[2])
if b >= len(s[1]):
	ans = s[0] + s[1] + '0' * (b - len(s[1]))
	print(ans)
else:
	ans = s[0] + s[1][:b] + '.' + s[1][b:]
	print(ans.rstrip('0').rstrip('.'))


s = input()
(a, s) = s.split('.')
(d, b) = s.split('e')
for i in range(int(b)):
	d += '0'
	a += d[0]
	d = d[1:]
s = a + '.' + d
while s[0] == '0':
	s = s[1:]
while s[-1] == '0':
	s = s[:-1]
if s[-1] == '.':
	s = s[:-1]
if s == '' or s[0] == '.':
	s = '0' + s
print(s)


(a, b) = input().split('e')
b = int(b)
p = len(a)
q = a.index('.')
a = a[:q] + a[q + 1:q + b + 1] + '.' + a[q + b + 1:]
while a[-1] == '0':
	a = a[:-1]
if a[-1] == '.':
	a = a[:-1] + '0' * (b - (p - q - 1))
print(a)


s = input()
(d, tmp) = s.split('.')
(r, exp) = tmp.split('e')
if (int(d) == 0) & (int(r) == 0):
	print('0')
else:
	result = ''
	rlen = len(r)
	if rlen <= int(exp):
		tmp = int(exp) - rlen
		zeros = ''
		while tmp > 0:
			zeros = zeros + '0'
			tmp -= 1
		result = d + r + zeros
	else:
		tmp1 = r[:int(exp)]
		tmp2 = r[int(exp):]
		if int(tmp2) == 0:
			result = d + tmp1
		else:
			result = d + tmp1 + '.' + tmp2
	i = 0
	count = 0
	while (result[i] == '0') & (i + 1 < len(result)):
		if result[i + 1] != '.':
			count += 1
		i += 1
	print(result[count:])


(a, deb) = input().split('.')
(d, b) = deb.split('e')
b = int(b)
if b < len(d):
	number = '{}{}.{}'.format(a, d[:b], d[b:])
	number = number.strip('0')
	if number[0] == '.':
		number = '0{}'.format(number)
	if number[-1] == '.':
		number = number[:-1]
else:
	number = '{}{}{}'.format(a, d, '0' * (b - len(d)))
	number = number.lstrip('0')
	if not number:
		number = '0'
print(number)


s = input()
i = len(s) - 1
while s[i] != 'e':
	i -= 1
b = int(s[i + 1:len(s)])
j = 0
while s[j] != '.':
	j += 1
p = ''
if s[i - 1] == '0':
	p = s[0:j]
	for i in range(b):
		p = p + '0'
elif i - j > b + 1:
	p = s[0:j] + s[j + 1:j + b + 1] + '.' + s[j + b + 1:i]
else:
	p = s[0:j] + s[j + 1:i] + s[j + b + 1:i]
	for i in range(b - (i - j - 1)):
		p = p + '0'
print(p)


from decimal import *
a = input()
b = Decimal(a)
if round(b) == b:
	print(round(b))
else:
	print(b)


from decimal import Decimal

def isint(n):
	return n == int(n)
s = input()
ss = Decimal(s)
if isint(ss):
	print(int(ss))
else:
	print(ss)


(m, b) = input().split('e')
b = int(b)
(a, d) = m.split('.')
if d == '0':
	print(a + '0' * b)
elif len(d) > b:
	print(a, d[:b], '.', d[b:], sep='')
else:
	print(a, d, '0' * (b - len(d)), sep='')


from decimal import *
n = Decimal(input())
if int(n) == n:
	print(int(n))
else:
	print(n)


from decimal import *
SciNum = Decimal(input())
print([SciNum, int(SciNum)][int(SciNum) == SciNum])


import sys

def main():
	line = sys.stdin.readline().strip()
	result = solve(line)
	sys.stdout.write(result + '\n')

def solve(line):
	e_ind = line.index('e')
	exponent = int(line[e_ind + 1:])
	mantissa = line[:e_ind]
	mant_ceil = mantissa[:mantissa.index('.')]
	mant_fraction = mantissa[mantissa.index('.') + 1:]
	if exponent == 0:
		f = ''
		if len(mant_fraction) != 0 and mant_fraction != '0':
			f = '.' + str(mant_fraction)
		return str(mant_ceil) + f
	result = mant_ceil
	i = 0
	while exponent > 0:
		result += mant_fraction[i] if i < len(mant_fraction) else '0'
		exponent -= 1
		i += 1
	if i < len(mant_fraction):
		result += '.'
	while i < len(mant_fraction):
		result += mant_fraction[i]
		i += 1
	return result
main()


s = input()
a = s.split('e')[0].split('.')[0]
d = s.split('e')[0].split('.')[1]
b = int(s.split('e')[1])
if int(d) == 0:
	d = ''
if len(d) <= b:
	a += d
	for i in range(b - len(d)):
		a += '0'
else:
	for i in range(b):
		a += d[i]
	a += '.'
	for i in range(b, len(d)):
		a += d[i]
p = list(a.split('.')[0])
while len(p) > 1 and p[0] == '0':
	del p[0]
p = ''.join(p)
if len(a.split('.')) > 1:
	a = p + '.' + a.split('.')[1]
else:
	a = p
print(a)


s = input().strip()
pi = s.find('.')
ei = s.find('e')
a = s[:pi]
d = s[pi + 1:ei]
b = s[ei + 1:]
b = int(b)
ld = len(d)
if ld < b:
	d += '0' * (b - ld)
dafter = d[:b] + '.' + d[b:]
numafter = a + dafter
num = numafter.strip('0')
if num[0] == '.':
	num = '0' + num
if num[-1] == '.':
	num = num[:-1]
print(num)


from decimal import Decimal

def barnikl(n):
	m = Decimal(n)
	if int(m) == m:
		return int(m)
	return str(m)
print(barnikl(input()))


(c, b) = input().split('e')
(a, d) = c.split('.')
if len(d) <= int(b):
	while len(d) < int(b):
		d += '0'
	a += d
	while len(a) > 1 and a[0] == '0':
		a = a[1:]
else:
	a = a + d[:int(b)] + '.' + d[int(b):]
	while a[0] == '0' and a[1] != '.':
		a = a[1:]
	if all((x == '0' for x in a.split('.')[1])):
		a = a[:-2]
print(a)


leer = input()
leer = leer.split('e')
listo = 0
numero = int(leer[1])
valor = leer[0]
valor = valor.split('.')
if len(valor[1]) < numero:
	tamIni = len(valor[1])
	for i in range(0, numero - tamIni):
		valor[1] += '0'
aux = valor[1][0:numero]
aux2 = valor[1][numero:len(valor[1])]
for i in range(0, len(aux2)):
	if aux2[i] == '0':
		Cero = True
	else:
		Cero = False
		break
if aux2:
	if Cero == False:
		resultado = str(valor[0]) + str(aux) + '.' + str(aux2)
	else:
		resultado = str(valor[0]) + str(aux)
else:
	resultado = str(valor[0]) + str(aux)
for i in range(0, len(resultado)):
	if resultado[i] == '0':
		Cero = True
	else:
		Cero = False
		break
if Cero == True:
	print('0')
else:
	print(resultado)


import sys
line = sys.stdin.readline()
(a, deb) = line.split('.')
(d, b) = deb.split('e')
if d == '0':
	d = ''
b = int(b)
p1 = d[0:b]
if len(p1) < b:
	p1 = p1 + '0' * (b - len(p1))
p2 = d[b:]
print(a + p1 + ('.' + p2 if p2 != '' else ''))


s = input()
i = s.find('e')
s1 = s[0] + s[2:i]
a = int(s[i + 1:len(s)])
if a + 1 <= len(s1):
	s = s1[0:a + 1]
if a + 1 < len(s1):
	s = s + '.'
	for j in range(a + 1, len(s1)):
		s = s + s1[j]
else:
	s = s1
	for j in range(len(s1), a + 1):
		s = s + '0'
i = 0
while s[i] == '0':
	s = s[1:len(s)]
if s[0] == '.':
	s = '0' + s
if s[len(s) - 1] == '0' and s[len(s) - 2] == '.':
	s = s[0:len(s) - 2]
print(s)


s = input()
l = []
for i in s:
	if i == 'e':
		break
	if i == '.':
		continue
	l.append(i)
exp = int(s[s.index('e') + 1:len(s)])
out = ''
if exp > len(l) - 1:
	out = ''.join(l) + '0' * (exp - len(l) + 1)
else:
	l.insert(exp + 1, '.')
	out = ''.join(l)
if out[len(out) - 1] == '.':
	out = out[:len(out) - 1]
if out[1] != '.':
	out = out.lstrip('0')
if '.' in out:
	out = out.rstrip('0')
out = out.rstrip('.')
if float(out) == 0:
	print(0)
else:
	print(out)


(a, b, d) = input().replace('e', '.').split('.')
pos = len(a) + int(d)
if b == '0':
	b = ''
a = a + b
if pos > len(a):
	a += '0' * (pos - len(a))
if a[0] == '0' and pos > 1:
	a = a[1:]
	pos -= 1
if pos == len(a):
	print(a)
elif pos < len(a):
	print(a[:pos] + '.' + a[pos:])


from decimal import *
getcontext().prec = 100
x = Decimal(input())
if x == int(x):
	print(int(x))
else:
	print(x)


from decimal import *
a = Decimal(input())
if int(a) == a:
	print(int(a))
else:
	print(a)


(integer, fraction, degree) = input().replace('e', '.').split('.')
ans = integer
for i in range(len(fraction)):
	if i == int(degree):
		ans += '.'
	ans += fraction[i]
for i in range(int(degree) - len(fraction)):
	ans += '0'
if '.' in ans:
	(a, b) = ans.split('.')
	ans = str(int(a))
	if int(b) != 0:
		ans += '.' + b
print(ans)


from decimal import Decimal

def main():
	a = Decimal(input())
	if int(a) == a:
		print(int(a))
	else:
		print(str(a))
main()


s = input()
b = s.split('.')
a = [b[0], b[1].split('e')[0], b[1].split('e')[1]]
a[2] = int(a[2])
s = a[0]
for i in range(a[2]):
	if i < len(a[1]):
		s += a[1][i]
	else:
		s += '0'
if a[2] < len(a[1]):
	s += '.'
	for i in range(a[2], len(a[1])):
		s += a[1][i]
joke = False or len(s) == 1 or s[1] == '.'
j = ''
for i in range(len(s)):
	if not joke and s[i] == '0':
		pass
	elif not joke and s[i] != '0':
		joke = True
		j += s[i]
	else:
		j += s[i]
k = len(j)
if k >= 2 and j[-1] == '0' and (j[-2] == '.'):
	k -= 2
for i in range(k):
	print(j[i], end='')


def validate(ans, typ):
	if typ:
		ptr = 0
		while True:
			if ptr == len(ans):
				break
			if ans[ptr] != '0':
				break
			ptr += 1
		if ptr == len(ans):
			return '0'
		else:
			return ans[ptr:]
	else:
		(x, y) = ans.split('.')
		ptr = 0
		while True:
			if ptr == len(x):
				break
			if x[ptr] != '0':
				break
			ptr += 1
		ans = ''
		if ptr == len(x):
			ans += '0'
		else:
			ans += x[ptr:]
		ptr2 = len(y) - 1
		while True:
			if ptr2 < 0:
				break
			if y[ptr2] != '0':
				break
			ptr2 -= 1
		if ptr2 == -1:
			return ans
		else:
			return ans + '.' + y[:ptr2 + 1]
x = input().split('e')
prep = ''
stat = 0
cnt = 0
for i in x[0]:
	if stat == 1:
		cnt += 1
	if i != '.':
		prep += i
	if i == '.':
		stat = 1
add = int(x[1])
ans = ''
typ = 0
if cnt > add:
	cnt -= add
	get = len(prep) - cnt
	for i in range(get):
		ans += prep[i]
	ans += '.'
	for i in range(get, len(prep)):
		ans += prep[i]
else:
	typ = 1
	add -= cnt
	ans += prep + '0' * add
print(validate(ans, typ))


s = input()
(a, s) = s.split('.')
(d, b) = s.split('e')
a = int(a)
b = int(b)
if b == 0 and d == '0':
	print(a)
elif b > len(d):
	s = '0' * (b - len(d))
	print(a, d, s, sep='')
elif b == len(d):
	print(a, d, sep='')
else:
	print(a, d[:b], '.', d[b:], sep='')


from math import modf
s = input()
i = 0
while s[i] != 'e':
	i += 1
a = s[0:i]
b = int(s[i + 1:])
i = 0
while s[i] != '.':
	i += 1
a2 = a[i + 1:]
a = a[0:i]
i = 0
while b > 0 and i < len(a2):
	a += a2[i]
	i += 1
	b -= 1
if b > 0:
	while b > 0:
		a += '0'
		b -= 1
elif i < len(a2):
	a2 = a2[i:]
	a3 = ''
	i = len(a2) - 1
	k = 0
	while i > -1:
		if a2[i] != '0' and k == 0:
			k = 1
			a3 = a2[i] + a3
		elif k != 0:
			a3 = a2[i] + a3
		i -= 1
	if len(a3) != 0:
		a += '.'
		for i in range(len(a3)):
			a += a3[i]
print(a)


s = input()
fst = s[:s.index('e')]
to_move = int(s[s.index('e') + 1:])
curr = 0
while curr != to_move:
	if fst[-1] == '.':
		fst = fst[:-1] + '0.'
	else:
		prt = fst.split('.')
		fst = prt[0] + prt[1][0] + '.' + prt[1][1:]
	curr += 1
if fst[-1] == '.':
	fst = fst[:-1]
test = fst.split('.')
if len(test) != 1 and set(test[-1]) == {'0'}:
	fst = test[0]
print(fst)


t = input().split('e')
A = list(t[0])
B = int(t[1])
del A[1]

def pure(x):
	while x[0] == '0' and x[1] != '.':
		del x[0]
	return ''.join(x)
if B >= len(A) - 1:
	A += ['0' for i in range(B + 1 - len(A))]
	print(pure(A))
elif A == ['0', '0']:
	print(0)
elif B == 0 and A[1:] == ['0']:
	del A[1]
	print(pure(A))
else:
	A.insert(B + 1, '.')
	print(pure(A))


from decimal import *
x = Decimal(input())
if x == int(x):
	print(int(x))
else:
	print(x)


def get_number(string_number):
	string_number = str(string_number)
	a = string_number[0]
	d = string_number[2:string_number.find('e')]
	e = int(string_number[string_number.find('e') + 1:])
	if d == '0' and e == 0:
		return a
	elif e == len(d):
		return a + d
	elif e < len(d):
		num = a + d[:e] + '.' + d[e:]
		if num[len(num) - 1] == '.':
			return num[:len(num) - 1]
		else:
			return num
	else:
		return a + d + '0' * (e - len(d))
print(get_number(input()))


def main():
	(A, B) = input().split('e')
	B = int(B)
	(s1, s2) = A.split('.')
	if B == 0:
		if s2 == '0':
			print(s1)
		else:
			print(A)
		return
	print(s1, end='')
	for i in range(B):
		if i < len(s2):
			print(s2[i], end='')
		else:
			print(0, end='')
	s2 = s2[i + 1:]
	if s2:
		print('.' + s2)
main()


(a, b) = input().split('e')
b = int(b)
c = ''
d = a.index('.')
for i in range(d):
	c += a[i]
n = len(a) - d - 1
if b < n:
	i = d + 1
	for j in range(b):
		c += a[i + j]
	c += '.'
	i += b
	k = i - 1
	f = 0
	while i < len(a):
		c += a[i]
		if a[i] != '0':
			f = 1
		i += 1
	if f == 1:
		print(c)
	else:
		print(c[:k])
else:
	i = d + 1
	for j in range(n):
		c += a[i + j]
	for i in range(b - n):
		c += '0'
	print(c)


s = input()
a = s[0]
s = s[2:]
b = s[:s.find('e')]
d = int(s[s.find('e') + 1:])
s = ''
if d < 0:
	s = '0.' + a
	d -= 1
	s += '0' * -d
	d = 0
	s += b
else:
	s = a
	while d > 0:
		s += b[0]
		b = b[1:] + '0'
		d -= 1
	s += '.' + b
while len(s) and s[0] == '0':
	s = s[1:]
s = s[::-1]
while len(s) and s[0] == '0':
	s = s[1:]
s = s[::-1]
if s[0] == '.':
	s = '0' + s
if s[-1] == '.':
	s = s[:-1]
print(s)


import sys
(a, b) = input().split('e')
l1 = len(a)
(c, d) = a.split('.')
l2 = int(b)
if a[0] == '0' and d[0] == '0':
	print(0)
	sys.exit(0)
if d == '0':
	d = ''
print(c, end='')
for i in range(min(l2, len(d))):
	print(d[i], end='')
if l2 > len(d):
	print('0' * (l2 - len(d)))
elif l2 < len(d):
	print('.', end='')
	for i in range(l2, len(d)):
		print(d[i], end='')


def main():
	s = input()
	print(solver(s))

def solver(s):
	(baseS, expS) = s.split('e')
	exp = int(expS)
	nS = baseS[:firstTrailingZero(baseS)]
	if len(nS) - 2 > exp:
		nS = nS[0] + nS[2:exp + 2] + '.' + nS[exp + 2:]
	else:
		nS = nS[0] + nS[2:] + '0' * (exp - len(nS) + 2)
	return nS

def firstTrailingZero(s):
	index = len(s) - 1
	while s[index] == '0':
		index -= 1
	return index + 1
main()


n = input().split('e')
z = int(n[1])
res = n[0][0]
i = 2
while z > 0:
	res += n[0][i] if i < len(n[0]) else '0'
	z -= 1
	i += 1
if i < len(n[0]) and n[0][i:] != '0':
	res += '.' + n[0][i:]
print(res)


s = input()
ind = s.find('e')
d = int(s[ind + 1:])
z = s.find('.')
a = s[:z]
b = s[z + 1:ind]
ans = a
for k in range(d):
	if len(b) <= k:
		ans += '0'
	else:
		ans += b[k]
if d < len(b):
	ans += '.'
	ans += b[d:]
i1 = ans.find('.')
bo = True
if i1 == -1:
	bo = False
	ans1 = ans
else:
	ans1 = ans[:i1]
	ans2 = ans[i1 + 1:]

def cl1(ans1):
	k = 0
	while k < len(ans1) - 1:
		if ans1[k] != '0':
			break
		else:
			ans1 = ans1[k + 1:]
	if ans1 == None:
		ans1 = 0
	return ans1

def cl2(ans2):
	for i in range(len(ans2)):
		k = ans2[i:]
		if k.count('0') == len(k):
			ans2 = ans2[:i]
			break
	return ans2
if bo:
	ans1 = cl1(ans1)
	ans2 = cl2(ans2)
	total = ans1 + '.' + ans2
	if total.endswith('.'):
		print(total[:-1])
	else:
		print(total)
else:
	print(cl1(ans1))


def main():
	x = input()
	dot = x.find('.')
	e = x.find('e')
	a = x[:dot]
	d = x[dot + 1:e]
	b = int(x[e + 1:])
	if b > len(d):
		for _ in range(b - len(d)):
			d += '0'
	p = a + d[:b]
	q = d[b:]
	if p.startswith('00'):
		p = p.lstrip('0')
		if p == '':
			p = '0'
	if q.endswith('0'):
		q = q.rstrip('0')
	ans = p
	if q != '':
		ans = ans + '.' + q
	print(ans)
main()


s = input()
a = s[0]
(d, b) = list(s[2:].split('e'))
if a == '0':
	print(0 if d == '0' else '0.' + d)
else:
	b = int(b)
	len_d = len(d)
	if b == 0 and d == '0':
		print(a)
	else:
		print(a + d[:b] + '.' + d[b:] if b < len_d else a + d + '0' * (b - len_d))


s = input()
s = s.replace('e', '.')
(a, b, c) = s.split('.')
if int(c) >= len(b):
	ans = list(a + b + (int(c) - len(b)) * '0')
	if ans[0] == '0':
		del ans[0]
	print(''.join(ans))
else:
	ans = list(a + b)
	if b == '0' and c == '0':
		print(a)
	else:
		ans.insert(len(a) + int(c), '.')
		dot = ans.index('.')
		if dot != 1 and ans[0] == '0':
			del ans[0]
		print(''.join(ans))


from sys import stdin, stdout
from decimal import *
a = Decimal(input())
print([a, '%d' % a][int(a) == a])


from decimal import Decimal
import sys
s = input().split('e')
a = s[0]
left_e = a.split('.')
lef_point = []
b = int(s[1])
m = []
z = 0
final_val = []
if left_e[1] == '0' and s[1] == '0':
	print(left_e[0])
	sys.exit()
lef_point.append(left_e[0])
for t in left_e[1]:
	m += t
q = m[:b]
if len(left_e[1]) < b:
	while z < b - len(left_e[1]):
		q.append('0')
		z += 1
t = q + ['.'] + m[b:len(m)]
final_val = lef_point + t
if final_val[len(final_val) - 1] == '.':
	final_val.remove('.')
for k in final_val:
	print(k, sep='', end='')


inp = input()
(a, inp) = inp.split('.')
(d, b) = inp.split('e')
b = int(b)
whole = a + d
ans = ''
if b >= len(d):
	ans = d + '0' * (b - len(d))
	if a != '0':
		ans = a + ans
else:
	ans = a + d[:b]
	if len(ans) > 1 and ans[0] == '0':
		ans = d[:b]
	if d[b:] != '0':
		ans += '.' + d[b:]
print(ans)


inp = input().split('.')
x = inp[1].split('e')
if len(x[0]) > int(x[1]):
	ans = inp[0] + x[0][0:int(x[1])] + '.' + x[0][int(x[1]):]
elif len(x[0]) == int(x[1]):
	ans = inp[0] + x[0] + '.0'
else:
	ans = inp[0] + x[0] + '0' * (int(x[1]) - len(x[0])) + '.0'
x = ans.split('.')
if int(x[1]) == 0:
	print(x[0])
else:
	print(ans)


s = input()
exp = int(s[s.index('e') + 1:])
num = [i for i in s[:s.index('e')]]
if ''.join(num) == '0.0':
	print(0)
else:
	if num[0] == 0:
		num.pop(0)
	ind = num.index('.')
	for i in range(ind, len(num) - 1):
		if exp > 0:
			exp -= 1
			(num[i], num[i + 1]) = (num[i + 1], num[i])
	if exp >= 0 and num[-1] == '.':
		num.pop(-1)
		num += ['0'] * exp
	while num[0] == '0':
		num.pop(0)
	if num[0] == '.':
		num = ['0'] + num
	st = ''.join(num)
	if '.' in num:
		ok = True
		for i in num[num.index('.') + 1:]:
			if i != '0':
				ok = False
		print(st[:st.index('.')] if ok else st)
	else:
		print(st)


from collections import *
import os, sys
from io import BytesIO, IOBase

def main():
	s = rstr()
	e = s.index('e')
	(d, b, ans) = ([s[j] for j in range(2, e)][::-1], int(s[e + 1:]), [s[0]])
	while b and d:
		ans.append(d.pop())
		b -= 1
	if d and d.count('0') != len(d):
		ans.extend(['.'] + d[::-1])
	else:
		ans.extend(['0'] * b)
	be = 0
	for i in range(len(ans) - 1):
		if ans[i] == '0' and ans[i + 1] != '.':
			be += 1
		else:
			break
	print(*ans[be:], sep='')

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
BUFSIZE = 8192
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
rstr = lambda : input().strip()
rstrs = lambda : [str(x) for x in input().split()]
rstr_2d = lambda n: [rstr() for _ in range(n)]
rint = lambda : int(input())
rints = lambda : [int(x) for x in input().split()]
rint_2d = lambda n: [rint() for _ in range(n)]
rints_2d = lambda n: [rints() for _ in range(n)]
ceil1 = lambda a, b: (a + b - 1) // b
main()


__author__ = 'Utena'
(b1, c) = input().split('e')
(a, b) = b1.split('.')
c = int(c)
if a == '0' and b == '0':
	print(0)
	exit(0)
if b == '0':
	b = ''
if len(b) <= c:
	print(a + b + '0' * (c - len(b)))
else:
	print(a + b[:c] + '.' + b[c:])


from decimal import *

def full(d):
	return d.quantize(Decimal(1)) if d == d.to_integral() else d.normalize()
getcontext().prec = 400
print(full(Decimal(input())))


import decimal
decimal.getcontext().prec = 999

def main():
	(x, e) = input().split('e')
	num = decimal.Decimal(x)
	e = int(e)
	num *= 10 ** e
	s = '{:.1000f}'.format(num).rstrip('0')
	if s[-1] == '.':
		return s[:-1]
	return s
print(main())


(s, b) = input().split('e')
(a, d) = s.split('.')
if int(a) == 0:
	if int(d) == 0:
		print(0)
	elif int(b) == 0:
		print(a + '.' + d)
	else:
		d = list(d)
		b = int(b)
		if b < len(d):
			d.insert(b, '.')
			print(''.join(d))
		else:
			k = b - len(d)
			print(''.join(d) + '0' * k)
else:
	a = list(a)
	d = list(d)
	b = int(b)
	if b < len(d):
		d.insert(b, '.')
		K = ''.join(a + d)
		if K.split('.')[1] == '0':
			print(K.split('.')[0])
		else:
			print(K)
	else:
		k = b - len(d)
		print(''.join(a + d) + '0' * k)


from sys import stdin
str = stdin.readline()
l = len(str)
e = str.index('e')
a = str[0]
b = int(str[e + 1:l])
d = str[2:e]
if b == 0:
	if d == '0':
		newstr = str[0]
	else:
		newstr = str[0] + '.' + d[0:e]
elif b < len(d):
	newstr = str[0] + d[0:b] + '.' + d[b:e]
elif b == len(d):
	newstr = str[0] + d[0:e]
else:
	newstr = str[0] + d[0:e] + '0' * (b - len(d))
print(newstr)


from decimal import *
getcontext().prec = 101
x = Decimal(input())
print(x if x != x.to_integral_value() else x.quantize(Decimal(1)))


import math
num = input()
(a, b) = num.split('e')
(a, c) = a.split('.')
b = int(b)
erg = a + c[:b]
erg += '0' * max(0, b - len(c))
c = c[b:]
c = c.rstrip('0')
if c:
	erg = erg + '.' + c
erg = erg.lstrip('0')
if not erg:
	erg = '0'
if erg[0] == '.':
	erg = '0' + erg
print(erg)


l = input()
a = l[:l.find('.')]
d = l[l.find('.') + 1:l.find('e')]
b = int(l[l.find('e') + 1:]) + 1
l = a + d
while len(l) > 0 and l[0] == '0':
	l = l[1:]
	b -= 1
while len(l) > 0 and l[-1] == '0':
	l = l[:-1]
else:
	if b <= 0:
		l = '0' + l
		b = 1
	if b < len(l):
		print(l[:b] + '.' + l[b:])
	else:
		while b > len(l):
			l += '0'
		print(l)


(a, d) = input().split('.')
(d, b) = d.split('e')
b = int(b)
if b <= len(d):
	a = a + d[:b]
	d = d[b:]
else:
	a = a + d + '0' * (b - len(d))
	d = ''
while len(a) > 1 and a[0] == '0':
	a = a[1:]
if len(d) == 0 or d == '0':
	print(a)
else:
	print('{}.{}'.format(a, d))


n = input()
(left, right) = n.split('e')
a = left[0]
d = left[2:]
b = int(right)
ind = n.index('.')
move = ind + b
word = a + d
if len(word) < move:
	while len(word) < move:
		word += '0'
	print(int(word))
	exit(0)
elif len(word) == move:
	print(int(word))
else:
	a = word[:move]
	d = word[move:]
	d = d.rstrip('0')
	if not d:
		print(a)
	else:
		print(a + '.' + d)


from math import floor
from decimal import *
getcontext().prec = 100
a = Decimal(input())
if a - floor(a) == 0:
	print(floor(a))
else:
	print(a)


import decimal
N = input()
s = str(N)
s = s.split('e')
pw = int(s[1])
fl = s[0]
fl = fl.split('.')
f1 = fl[0]
f2 = fl[1]
ans = f1 + f2
pw = pw - len(f2)
if pw >= 0:
	ans = ans + '0' * pw
elif len(ans) > pw:
	ans = ans[:pw] + '.' + ans[pw:]
else:
	ans = '0.' + '0' * (pw - len(ans)) + ans
print(ans.rstrip('0').rstrip('.') if '.' in ans else ans)


import sys

def main():
	num = stdin_get_string_from_line()
	(num, e) = num.split('e')
	(intg, noint) = num.split('.')
	ee = int(e)
	nointl = len(noint)
	if ee == 0 and noint != '0':
		return num
	if ee == 0 and noint == '0':
		return intg
	if nointl == ee:
		return intg + noint
	elif nointl < ee:
		how_many = ee - nointl
		for _ in range(how_many):
			noint += '0'
		return intg + noint
	a = noint[0:ee]
	b = noint[-(nointl - ee):]
	return intg + a + '.' + b

def stdin_get_ints_from_line():
	return (int(x) for x in sys.stdin.readline().strip().split(' '))

def stdin_get_ints_list_from_line():
	return list((int(x) for x in sys.stdin.readline().strip().split(' ')))

def stdin_get_string_from_line():
	return sys.stdin.readline().strip()
print(main())


s = input()
b = int(s.split('e')[1])
s = s.split('e')[0]
a = s.split('.')[0]
d = s.split('.')[1] + '0' * 101
a += d[:b]
d = d[b:]
i = 0
while i < len(a) - 1 and a[i] == '0':
	i += 1
a = a[i:]
i = len(d) - 1
while i > 0 and d[i] == '0':
	i -= 1
d = d[:i + 1]
if d == '0':
	print(a)
else:
	print(a + '.' + d)


def main():
	s = input()
	print(solver(s))

def solver(s):
	(baseS, expS) = s.split('e')
	exp = int(expS)
	nS = None
	if len(baseS) - 2 >= exp:
		nS = baseS[0] + baseS[2:exp + 2] + '.' + baseS[exp + 2:]
		(wholePart, decPart) = nS.split('.')
		if decPart == '0' * len(decPart):
			return wholePart
		else:
			return nS
	else:
		nS = baseS[0] + baseS[2:] + '0' * (exp - len(baseS) + 2)
		return nS
main()


s = input()
s = s.replace('e', '.')
L = s.split('.')
b = int(L[2])
w = L[0]
d = L[1]
if b < len(d):
	w = w + d[:b] + '.' + d[b:]
elif b == len(d):
	w = w + d
else:
	w = w + d + (b - len(d)) * '0'
if w[:-1] == '.':
	w = w[:-1]
if w[-2:] == '.0':
	w = w[:-2]
print(w)


(a, b) = input().split('.')
(c, d) = b.split('e')
d = int(d)
if d >= 0:
	c = c + (d - len(c)) * '0'
	r = a + c[:d] + '.' + c[d:]
elif -d >= len(a):
	r = '0.' + (-d - len(a)) * '0' + a[d:] + c
else:
	r = a[:-d] + '.' + a[-d:] + c
if r[-2:] == '.0':
	print(r[:-2])
else:
	print(r.rstrip('.'))


sci = input().strip()
(num, exp) = sci.split('e')
ad = ''.join(num.split('.'))
e = int(exp)
(a, d) = map(int, num.split('.'))
if a == 0 and d == 0:
	print(0)
else:
	res = ad[:1 + e]
	if 1 + e < len(ad):
		res += '.' + ad[1 + e:]
		j = len(res) - 1
		while res[j] == '0':
			j -= 1
		if res[j] == '.':
			j -= 1
		res = res[:j + 1]
	elif 1 + e > len(ad):
		res = ad + '0' * (1 + e - len(ad))
	i = 0
	while res[i] == '0':
		i += 1
	if res[i] == '.':
		print('0', end='')
	print(res[i:], end='')
print()


(a, b) = input().split('e')
b = int(b)
(c, d) = a.split('.')
d += '0' * 500
ans = c + d[:int(b)] + '.' + d[int(b):]
while ans[len(ans) - 1:] == '0':
	ans = ans[:len(ans) - 1]
if ans[len(ans) - 1:] == '.':
	ans = ans[:len(ans) - 1]
print(ans)


(mantissa, exponent) = input().split('e')
(a, d) = mantissa.split('.')
exponent = int(exponent)
number = a + d[0:min(exponent, len(d))] + ('0' * (exponent - len(d)) if exponent >= len(d) else '.' + d[exponent:])
number = number.lstrip('0')
if number.count('.') > 0:
	number = number.rstrip('0')
if number[0] == '.':
	number = '0' + number
if number[-1] == '.':
	number = number[:-1]
print(number)


(whole, part, power) = input().replace('.', ' ').replace('e', ' ').split()
power = int(power)
if power >= len(part):
	outnum = (whole + part + '0' * (power - len(part))).lstrip('0')
	if not outnum:
		outnum = '0'
else:
	outnum = '{}.{}'.format(whole + part[:power], part[power:]).lstrip('0')
	if outnum[0] == '.':
		outnum = '0' + outnum
	if outnum.rstrip('0')[-1] == '.':
		outnum = outnum.split('.')[0]
print(outnum)


from decimal import *
import math
x = input()
x = Decimal(x)
y = int(x)
if x == y:
	x = int(x)
print(x)


from decimal import *
while True:
	try:
		a = input()
		b = Decimal(a)
		if round(b) == b:
			print('%d' % b)
		else:
			print(b)
	except:
		break


s = input()
(a, b) = s.split('e')
(a, d) = a.split('.')
b = int(b)
if b == 0:
	if d != '0':
		print(a + '.' + d)
	else:
		print(a)
elif b >= len(d):
	print(a + d + '0' * (b - len(d)))
elif b > 0:
	print(a + d[0:b] + '.' + d[b:])
elif -b >= len(a):
	print('0.' + '0' * (-len(a) - b) + d)
else:
	print(a[:-b - 1] + '.' + a[-b - 1:] + d)


(a, b) = input().split('e')
b = int(b)
(c, d) = a.split('.')
d += '0' * 100
ans = c + d[:int(b)] + '.' + d[int(b):]
while ans[-1] == '0':
	ans = ans[:-1]
if ans[-1] == '.':
	ans = ans[:-1]
print(ans)


def main():
	num = input()
	(val, exp) = num.split('e')
	if exp == '0':
		if val == '0.0':
			print(0)
		else:
			val = val.rstrip('0')
			if len(val) > 2:
				print(val)
			else:
				print(val[:-1])
		return
	exp = int(exp)
	(whole, frac) = val.split('.')
	i = len(whole)
	number = ''.join([whole, frac])
	if i + exp == len(number):
		pass
	elif i + exp < len(number):
		number = '.'.join([number[:i + exp], number[i + exp:]])
	else:
		zeros = i + exp - len(number)
		number = ''.join([number] + ['0'] * zeros)
	print(number.lstrip('0'))
main()


from functools import reduce
import math
from decimal import *

def factors(n):
	return set(reduce(list.__add__, ([i, n // i] for i in range(1, int(n ** 0.5) + 1) if n % i == 0)))

def sol():
	a = Decimal(input())
	if int(a) == a:
		print(int(a))
	else:
		print(a)
sol()


import decimal
import math
num = input()
num1 = decimal.Decimal(num)
if math.floor(num1) == num1:
	print('%d' % num1)
else:
	print(num1)


s = input()
bf = s[len(s) - 4:]
eindex = len(s) - (4 - bf.index('e'))
b = int(bf[bf.index('e') + 1:])
x = eindex - (2 + b)
dlen = eindex - 2
print(s[0], end='')
if dlen == 1 and s[2] == '0' and (b == 0):
	pass
elif dlen > b:
	print(s[2:2 + b], end='')
	print('.', end='')
	print(s[2 + b:eindex])
elif dlen == b:
	print(s[2:2 + b], end='')
elif dlen < b:
	print(s[2:eindex], end='')
	print('0' * (b - dlen), end='')


line = input()
s = ''
k = len(line)
while line[k - 1] != 'e':
	s = line[k - 1] + s
	k = k - 1
line1 = list(line[:k - 1])
b = int(s)
for i in range(0, len(line1)):
	if line1[i] == '.':
		line1.pop(i)
		j = i + b
		if j <= len(line1):
			line1.insert(j, '.')
			u = len(line1) - 1
			dif = 0
			while u > j and line[u] == '0':
				line1.pop()
				u -= 1
		else:
			dif = j - len(line1)
			line1 = line1 + ['0'] * dif
		break
if line1[-1] == '.':
	line1.pop()
print(''.join((y for y in line1)))


from decimal import *
import re
getcontext().prec = 1000
i = input().strip()
(number, exp) = map(Decimal, i.split('e'))
number *= 10 ** int(exp)
if int(number) - number == 0:
	print(int(number))
else:
	print(re.sub('0+$', '', str(number)))


t = input()
x = t.find('e')
if t[:x].endswith('.0'):
	t = t.replace('.0', '')
	x = t.find('e')
	b = t[:x]
	c = int(t[x + 1:])
	t = b + '0' * c
	print(t)
elif '.' not in t:
	b = t[:x]
	c = int(t[x + 1:])
	print(b + '0' * c)
else:
	y = t.find('.')
	c = int(t[x + 1:])
	if x - y - 1 <= c:
		t = t.replace('.', '')
		t = t.lstrip('0')
		c1 = t.find('e')
		t = t[:c1] + '0' * (c - x + y + 1)
		t = t.rstrip('.')
		print(t)
	else:
		t = t.replace('.', '')
		t = t[:y + c] + '.' + t[y + c:x - 1]
		t = t.lstrip('0')
		z = float(t)
		if z < 1:
			t = '0' + t
		print(t)


s = input()
p1 = s.index('.')
p2 = s.index('e')
a = s[0:p1]
d = s[p1 + 1:p2]
b = s[p2 + 1:]
if a == '0' or b == '0':
	if d == '0':
		print(a)
	else:
		print(a + '.' + d)
	exit(0)
t = ['0'] * int(b)
if len(d) <= int(b):
	for i in range(len(d)):
		t[i] = d[i]
	ts = ''.join(t)
	res = a + ts
else:
	res = a + d[0:int(b)] + '.' + d[int(b):]
print(res)


str = input()
lis = list(str.split('e'))
cnt = 0
s = lis[0]
flg = 0
pow = int(lis[1])
if float(s) == 0:
	print(0)
	exit(0)
if pow == 0:
	b = s.split('.')[1]
	if b == '0' * len(b):
		print(s.split('.')[0])
	else:
		print(s)
	exit(0)
for x in range(len(s)):
	if cnt == pow:
		print('.', end='')
	if s[x] != '.':
		print(s[x], end='')
	else:
		flg = 1
		continue
	if flg:
		cnt += 1
while cnt < pow:
	print('0', end='')
	cnt += 1


import re
p = re.compile('(\\d*)\\.(\\d*)e(\\d*)')
x = str(input())
z = re.findall(p, x)
z = z[0]
a = z[0]
d = z[1]
b = z[2]
res = int(b) - len(d)
ans = a + d[0:int(b)] + '.' + d[int(b):]
if ans[len(ans) - 1] == '.':
	ans = ans[:len(ans) - 1]
while len(ans) > 0:
	if ans[0] == '0':
		ans = ans[1:]
	else:
		break
if len(ans) > 0 and ans[0] == '.':
	ans = '0' + ans
if res > 0:
	ans += '0' * res
if ans.count('0') + ans.count('.') == len(ans):
	ans = '0'
zz = ans[ans.find('.') + 1:]
if zz.count('0') == len(zz):
	ans = ans[:ans.find('.')]
if len(ans) == 0:
	ans = '0'
print(ans)


from sys import stdout
from sys import stdin

def get():
	return stdin.readline().strip()

def getf():
	return [int(i) for i in get().split()]

def put(a, end='\n'):
	stdout.write(str(a) + end)

def putf(a, sep=' ', end='\n'):
	stdout.write(sep.join(map(str, a)) + end)

def isopen(s):
	return s in ['(', '{', '[', '<']

def main():
	s = input()
	n = len(s)
	for i in range(n):
		if s[i] == 'e':
			e = int(s[i + 1:])
			ln = i
	s = [s[0]] + list(s[2:ln]) + ['0'] * e
	n = len(s)
	x = n - ln + 2
	s.insert(x, '.')
	j = n
	while s[j] == '0':
		j -= 1
	if s[j] != '.':
		j += 1
	i = 0
	while s[i] == '0':
		i += 1
	if s[i] == '.':
		i -= 1
	putf(s[i:j], '')
main()


from decimal import *
a = Decimal(input())
print([a, '%d' % a][int(a) == a])


from decimal import *
res = Decimal(input())
print([res, int(res)][int(res) == res])


s = input()
n = len(s)
e_first_index = n - 1
while s[e_first_index] != 'e':
	e_first_index -= 1
e_first_index += 1
e = int(s[e_first_index:])
if s[0] == '0':
	if s[2:e_first_index - 1] == '0':
		print(0)
	else:
		print(s[:e_first_index - 1])
else:
	s = s[0] + s[2:e_first_index - 1]
	i_point = 1 + e
	n = len(s)
	if i_point == n:
		print(s[:n])
	elif i_point > n:
		s = s + '0' * (e - n + 1)
		print(s)
	elif s[n - 1] == '0' and i_point == n - 1:
		print(s[:n - 1])
	else:
		s = s[:i_point] + '.' + s[i_point:]
		print(s)


s = input()
(a, b) = s.split('e')
index = a.find('.')
ans = ''
if index == -1:
	b = '0' * int(b)
	ans = a + b
else:
	(a1, a2) = (a[:index], a[index + 1:])
	if int(a2) == 0:
		ans = a1 + '0' * int(b)
	elif len(a2) <= int(b):
		ans = a1 + a2 + '0' * (int(b) - len(a2))
	else:
		a2 = a2[:int(b)] + '.' + a2[int(b):]
		ans = a1 + a2
print(ans)


s = input()
toks = s.split('e')
if len(toks[0].split('.')) == 1:
	print(toks[0] + '0' * int(toks[1]))
	quit()
ind = toks[0].find('.')
a = toks[0].replace('.', '')
ans = a[:int(toks[1]) + 1] + '0' * (int(toks[1]) - len(toks[0].split('.')[1])) + '.' + a[int(toks[1]) + 1:]
if ans.endswith('.') or ans.split('.')[1].replace('0', '') == '':
	print(ans.split('.')[0])
	quit()
print(ans)


inp = input()
n = inp.split('e')
if inp == '0.0e0':
	print('0')
else:
	pos = list(n[0]).index('.')
	part = n[0].split('.')
	extra = int(n[1]) - len(part[1])
	p = 1
	if extra > 0:
		p = 0
		ez = ['0'] * extra
	else:
		if not extra:
			p = 0
		ez = []
	if not p:
		if part[0] == '0' and n[1] != '0':
			num = list(part[1]) + ez
		else:
			num = list(part[0]) + list(part[1]) + ez
	elif part[0] == '0' and n[1] != '0':
		num = list(part[1]) + ez
	else:
		q = list(part[1])
		q.insert(int(n[1]), '.')
		num = list(part[0]) + q
	num = ''.join(num)
	if p:
		digits = num.split('.')
		decimal = digits[1][::-1]
		decimal = int(decimal)
		if not decimal:
			print(digits[0])
		else:
			decimal = str(decimal)
			num = digits[0] + '.' + decimal[::-1]
			print(num)
	else:
		print(num)


s = input()
(a, temp) = s.split('.')
(d, b) = temp.split('e')
bb = int(b)
if a == '0':
	if d != '0':
		print(a, end='.')
		print(d)
	else:
		print(0)
elif bb == 0:
	if d != '0':
		print(a, end='.')
		print(d)
	else:
		print(a)
elif d == '0':
	print(a, end='')
	for i in range(bb):
		print('0', end='')
else:
	l = len(d)
	if l <= bb:
		print(a, end='')
		print(d, end='')
		temp2 = bb - l
		for i in range(temp2):
			print('0', end='')
	else:
		print(a, end='')
		for k in range(bb):
			print(d[k], end='')
		k += 1
		print('.', end='')
		print(d[k:])


s = input()
l = len(s)
(a, b, d) = (-1, -1, -1)
ae = 0
for i in range(l):
	if s[i] == '.':
		a = s[:i]
		ae = i
	elif s[i] == 'e':
		b = s[ae + 1:i]
		d = int(s[i + 1:])
if len(b) <= d:
	ans = int(a + b + '0' * (d - len(b)))
	print(ans)
else:
	ans = a + b[:d]
	flag = True
	for c in b[d:]:
		if c != '0':
			flag = False
	if not flag:
		ans += '.' + b[d:]
	print(ans)


s = input()
(a, b) = s.split('e')
b = int(b)
s = a.split('.')
dec = len(s[1])
f = ''
if s[0] != '0':
	f = s[0]
else:
	f = '0'
if b >= dec:
	f += s[1] + '0' * (b - dec)
else:
	f += s[1][:b] + '.' + s[1][b:]
if '.' in f:
	f = f.rstrip('0')
if f[-1] == '.':
	f = f[:-1]
if f[0] != '0':
	if f[0] == '0' and f[1] != '.':
		f = f[1:]
print(f)


N = input()
A = N.split('e')
exp = int(A[1])
num = A[0].split('.')
if exp < len(num[1]):
	u = num[0] + num[1][:exp]
	if int(num[1][exp:]) != 0:
		u += '.' + num[1][exp:]
	print(u)
elif exp == len(num[1]):
	u = num[0] + num[1]
	print(u)
else:
	u = num[0] + num[1] + '0' * (exp - len(num[1]))
	print(u)


(a, b) = input().split('e')
(a1, a2) = a.split('.')
if b == '0':
	if a2 == '0':
		print(a1)
	else:
		print(a)
elif len(a2) <= int(b):
	s = int(b) - len(a2)
	print(int(a1 + a2 + '0' * s))
else:
	s = int(b)
	print(a1 + a2[:s] + '.' + a2[s:])


base = input().split('e')
if base[0].find('.') > -1:
	base[0] = base[0].split('.')
	if int(base[1]) < len(base[0][1]) and int(base[0][1]) ** int(base[1]):
		if base[0][1][int(base[1]):] != '0':
			print(base[0][0] + base[0][1][:int(base[1])] + '.' + base[0][1][int(base[1]):])
		else:
			print(base[0][0] + base[0][1][:int(base[1])])
	else:
		print(base[0][0] + base[0][1][:int(base[1])] + '0' * (int(base[1]) - len(base[0][1])))
else:
	print(base[0] + '0' * int(base[1]))


scientific = input()
[l, b] = list(scientific.split('e'))
[a, d] = list(l.split('.'))
b = int(b)
if len(d) < b:
	d = d + '0' * (b - len(d))
	before = a + d
	after = ''
elif len(d) == b:
	before = a + d[:b]
	after = ''
else:
	before = a + d[:b]
	after = '.' + d[b:]
while len(before) > 1 and before[0] == '0' and (before[1] != '.'):
	before = before[1:]
if after == '.0':
	after = ''
print(before + after)


s = input()
l = s.split('e')
l1 = l[0].split('.')[0]
l2 = l[0].split('.')[1]
l3 = l[1]
l3 = int(l3)
razlika = l3 - len(l2)
tocka = len(l1) + l3
if razlika > 0:
	l2 += '0' * razlika
l1l2 = l1 + l2
l1l2 = l1l2[:tocka] + '.' + l1l2[tocka:]
while l1l2[0] == '0':
	l1l2 = l1l2[1:]
if l1l2[0] == '.':
	l1l2 = '0' + l1l2
while l1l2[-1:] == '0':
	l1l2 = l1l2[:-1]
if l1l2[-1:] == '.':
	l1l2 = l1l2[:-1]
print(l1l2)


(a, b) = input().split('e')
i = a.index('.')
f = a[:i]
l = a[i + 1:]
x = ''
if len(l) > int(b):
	x = f + l[:int(b)] + '.' + l[int(b):]
else:
	x = f + l + '0' * (int(b) - len(l))
if x[-2] + x[-1] == '.0':
	x = x[:-2]
print(x)


num = input()
int_num = ''
float_num = ''
m = 0
for i in range(len(num)):
	if i < num.find('.'):
		int_num = int_num + num[i]
	elif i < num.find('e') and num[i] != '.':
		float_num = float_num + num[i]
	elif i > num.find('e') and num[i] != 'e':
		m = m * 10 + int(num[i])
for i in range(m):
	if len(float_num) != 0:
		int_num = int_num + float_num[0]
		float_num = float_num[1:len(float_num)]
	else:
		int_num = int_num + '0'
if len(float_num) != 0:
	int_num = int_num + '.' + float_num
while int_num.find('.') != -1 and (int_num[len(int_num) - 1] == '0' or int_num[len(int_num) - 1] == '.'):
	int_num = int_num[0:len(int_num) - 1]
while len(int_num) >= 2 and int_num[0] == '0' and (int_num[1] != '.'):
	int_num = int_num[1:len(int_num)]
print(int_num)


from decimal import *
getcontext().prec = 1000
print('{0:f}'.format(Decimal(input()).normalize()))


line = input()
a = line.split('.')[0]
b = line.split('.')[1].split('e')[0]
c = int(line.split('.')[1].split('e')[1])
b += 1000 * '0'
a += b[:c]
b = b[c:]
if a.count('0') < len(a):
	pos = 0
	while a[pos] == '0':
		pos += 1
	a = a[pos:]
if b.count('0') == len(b):
	print(a)
else:
	pos = len(b) - 1
	while b[pos] == '0':
		pos -= 1
	print(a + '.' + b[:pos + 1])


def solve():
	S = input()
	e = S.find('e')
	lef = S[:e]
	rig = S[e + 1:]
	rig = int(rig)
	p = lef.find('.')
	ll = lef[:p]
	lr = lef[p + 1:]
	if len(lr) > rig:
		ans = ll + lr[:rig] + '.' + lr[rig:]
		ans = ans.rstrip('0').rstrip('.')
	elif len(lr) == rig:
		ans = ll + lr
	else:
		ans = ll + lr + '0' * (rig - len(lr))
	print(ans)
solve()


from decimal import *
n = input()
x = Decimal(n)
if round(x) == x:
	print('%d' % x)
else:
	print(x)


def main():
	l = input().split('e')
	e = int(l[1])
	(a, d) = l[0].split('.')
	if not int(d):
		d = ''
	s = ''.join((a, d[:e], '.', d[e:]) if len(d) > e else (a, d, '0' * (e - len(d))))
	for (i, c) in enumerate(s):
		if c != '0':
			if c == '.':
				i -= 1
			s = s[i:]
			break
	print(s)
main()


from decimal import *
getcontext().prec = 128
xs = input()
xs = [x for x in xs.split('e')]
a = Decimal(xs[0])
b = 10 ** int(xs[1])
s = str(a * b)
i = len(s) - 1
while i > 0 and s[i] == '0':
	i = i - 1
if s[i] == '.':
	i = i - 1
print(s[:i + 1])


from decimal import *
x = Decimal(input())
y = x.to_integral_value()
print(x if x != y else int(y))


def solve():
	s = input()
	(ad, b) = s.split('e')
	(a, d) = ad.split('.')
	ld = len(d)
	b = int(b)
	if d == '0' and b == 0:
		print(a)
	elif a == '0':
		print(ad)
	elif ld > b:
		print(a + d[:b] + '.' + d[b:])
	else:
		print(a + d + '0' * (b - ld))
solve()


S = input()
(A, B) = S.split('e')
(a1, a2) = A.split('.')
(s1, s2) = (a1[:] + a2[:int(B)], a2[int(B):])
while len(s1 + s2) < int(B) + 1:
	s1 = s1 + '0'
if len(s2) == 0 or int(s2) == 0:
	print(s1)
else:
	print(s1 + '.' + s2)


import re
inp = input()
m = re.search('(.*)[eE](.*)', inp)
a = m.group(1)
b = m.group(2)
dot = re.search('[.]', a)
if dot is None:
	if int(b) >= 0:
		print(a + '0' * int(b))
	elif len(a) > -int(b):
		print(a[:int(b)] + '.' + a[int(b):])
	else:
		print('0.' + '0' * (-int(b) - len(a)) + a)
else:
	a1 = re.search('(.*)\\.(.*)', a).group(1)
	a2 = re.search('(.*)\\.(.*)', a).group(2)
	if int(b) == 0:
		if int(a2) == 0:
			print(a1)
		else:
			print(a)
	elif int(b) > 0:
		if len(a2) > int(b):
			print(a1 + a2[:int(b)] + '.' + a2[int(b):])
		else:
			print(a1 + a2 + '0' * (int(b) - len(a2)))
	elif len(a1) > -int(b):
		print(a1[:int(b)] + '.' + a1[int(b):] + a2)
	else:
		print('0.' + '0' * (-int(b) - len(a1)) + a1 + a2)


from decimal import *
d = Decimal(input())
if int(d) == d:
	print(int(d))
else:
	print(d)


x = str(input())
inp = x.find('.')
ine = x.find('e')
a = x[0:inp]
d = x[inp + 1:ine]
b = x[ine + 1:]
if a == '0':
	if b == '0':
		if d == '0':
			print(a)
		else:
			print(a + '.' + d)
	else:
		print(d[0:int(b)] + '.' + d[int(b):])
elif len(d) < int(b):
	print(a + d + '0' * (int(b) - len(d)))
elif len(d[int(b):]) == 0 or d[int(b):] == '0':
	print(a + d[0:int(b)])
else:
	print(a + d[0:int(b)] + '.' + d[int(b):])


from decimal import Decimal, getcontext
getcontext().prec = 250
s = '{:.250f}'.format(Decimal(input()))
if '.' in s:
	while s[-1] == '0':
		s = s[:-1]
	if s[-1] == '.':
		s = s[:-1]
print(s)


from sys import stdin, stdout
(value, power) = stdin.readline().split('e')
ans = value[:value.index('.')] + value[value.index('.') + 1:min(len(value), value.index('.') + int(power) + 1)]
if len(value) <= value.index('.') + int(power) + 1:
	ans += '0' * (int(power) - len(value[value.index('.') + 1:]))
else:
	ans += '.' + value[value.index('.') + int(power) + 1:]
if ans.count('.'):
	(u, r) = ans.split('.')
	if r.count('0') != len(r):
		ans = str(int(u)) + '.' + r
	else:
		ans = str(int(u))
else:
	ans = str(int(ans))
stdout.write(ans)


calcul = input()
n = len(calcul)
e = None
for i in range(n):
	if calcul[i] == 'e':
		e = i
a = calcul[0]
d = calcul[2:e]
b = int(calcul[e + 1:])
if d == '0':
	d = ''
if len(d) == b:
	resultat = a + d
elif b > len(d):
	nombreZero = b - len(d)
	resultat = a + d + '0' * nombreZero
else:
	add = a + d
	virgule = b - len(d)
	resultat = add[:virgule] + '.' + add[virgule:]
	inf = 0
	sup = len(resultat) - 1
	while resultat[inf] == '0' and sup > inf:
		inf += 1
	while resultat[sup] == '0' and sup > inf:
		sup -= 1
	if resultat[inf] == '.':
		resultat = '0' + resultat[inf:sup + 1]
	else:
		resultat = resultat[inf:sup + 1]
print(resultat)


AeB = str(input()).replace('.', '')
e_pos = AeB.find('e')
A = AeB[:e_pos]
B = int(AeB[e_pos + 1:])
while 1:
	if B > 0 and A[0] == '0':
		A = A[1:]
		B = B - 1
	else:
		break
if int(A) == 0:
	print('0')
elif len(A) <= B + 1:
	result = A + '0' * (B + 2 - len(A))
	print(result[:-1])
else:
	result = A[:B + 1] + '.' + A[B + 1:]
	if int(A[B + 1:]) == 0:
		print(A[:B + 1])
	else:
		print(result)


s = input()
a = str()
b = str()
f = False
for i in range(len(s)):
	if s[i] == 'e':
		f = True
	elif f:
		b = b + s[i]
	else:
		a = a + s[i]
pos = a.index('.')
n = int(b)
a = list(a)
for i in range(n):
	if pos == len(a) - 1:
		a.append('0')
	(a[pos], a[pos + 1]) = (a[pos + 1], a[pos])
	pos += 1
if a[-1] == '.':
	a.pop()
if '.' in a:
	while a[-1] == '0':
		a.pop()
if a[-1] == '.':
	a.pop()
if '.' not in a:
	while len(a) > 1 and a[0] == '0':
		a.pop(0)
for i in range(len(a)):
	print(a[i], end='')


x = input()
(a, b) = x.split('e')
a = a.replace('.', '')
x = a[:int(float(b)) + 1] + '.' + a[int(float(b)) + 1:]
if len(a) - 1 < int(float(b)):
	x = x[:-1] + (int(float(b)) - len(a) + 1) * '0'
if x[-2:] == '.0':
	x = x[:-2]
if x[-1] == '.':
	x = x[:-1]
while len(x) >= 2 and x[0] == '0' and (x[1] == '0'):
	x = x[1:]
print(x)


s = str(input())
n = ''
e = ''
b = 0
for i in s:
	if i == 'e':
		b = 1
		continue
	if b == 0:
		n += i
	else:
		e += i
e = int(e)
if e == 0:
	if float(n) % 1 == 0:
		print(int(float(n)))
	else:
		print(n)
elif '.' not in n:
	for i in range(e):
		n += '0'
	k = 0
	for i in n:
		if i == '0':
			k += 1
		else:
			break
	if n[k:] == '':
		print(0)
	else:
		print(n[k:])
else:
	p = n.index('.')
	n = n[:p] + n[p + 1:]
	nl = len(n)
	if p + e >= nl:
		for i in range(p + e - nl):
			n += '0'
		k = 0
		for i in n:
			if i == '0':
				k += 1
			else:
				break
		if n[k:] == '':
			print(0)
		else:
			print(n[k:])
	else:
		n = n[:p] + '.' + n[p:]
		if e == 1:
			n = n[:p] + n[p + 1] + '.' + n[p + 2:]
		else:
			n = n[:p] + n[p + 1:p + e + 1] + '.' + n[p + e + 1:]
		k = 0
		for i in n:
			if i == '0':
				k += 1
			else:
				break
		nl = len(n)
		m = nl - 1
		while n[m] == '0':
			m -= 1
		if k == n.index('.'):
			print('0' + n[k:m + 1])
		else:
			print(n[k:m + 1])


(p, q) = input().split('e')
(a, b) = p.split('.')
b += '0' * 150
d = int(q)
a = (a + b[:d]).lstrip('0')
b = b[d:].rstrip('0')
if not a:
	a = '0'
print(a, end='')
if b:
	print('.' + b)
else:
	print()


from decimal import *
a = Decimal(input())
print([a, '%d' % a][a == round(a)])


(a, e) = input().split('e')
e = int(e) - len(a) + 2
a = a[0] + a[2:]
if e >= 0:
	print(a + '0' * e)
	exit()
a = int(a)
t = 10 ** (-e)
r = '.' + str(a % t + t)[1:]
if set(r) == set('.0'):
	r = ''
print(str(a // t) + r)


import math

def getDistance(sciNotationNum):
	(a, b) = sciNotationNum.split('e')
	if '.' not in a:
		for i in range(1, b + 1):
			a = a + '0'
		return a
	a = a.rstrip('0')
	b = int(b) - len(a.split('.')[1])
	a = a.replace('.', '')
	if b == 0:
		return a
	if b > 0:
		for i in range(1, b + 1):
			a = a + '0'
		return a
	else:
		return a[0:b] + '.' + a[b:]
sciNotationNum = input()
print(getDistance(sciNotationNum))


liste = input().split('e')
p = liste[0]
q = int(liste[1])
if '.' in p:
	num = p.split('.')
	dec = len(num[1])
	if num[1] != '0':
		if dec == q:
			p = num[0] + num[1]
		elif dec < q:
			p = num[0] + num[1] + '0' * (q - dec)
		else:
			p = num[0] + num[1][:q] + '.' + num[1][q:]
	else:
		p = num[0] + '0' * q
else:
	p += '0' * q
print(p)


s = input()
f = 0
for i in range(0, len(s)):
	if s[i] == 'e':
		e = i
b = int(s[e + 1:len(s)])
if e - 2 <= b:
	if s[0] != '0':
		for i in range(0, e):
			if s[i] != '.':
				print(s[i], end='')
		for i in range(e - 2, b):
			print('0', end='')
	else:
		for i in range(2, e):
			print(s[i], end='')
		for i in range(e - 2, b):
			print('0', end='')
else:
	if b == 0:
		for i in range(2, e):
			if s[i] == '0':
				f = f + 1
	if f == e - 2:
		print(s[0], end=' ')
		exit(0)
	else:
		print(s[0], end='')
		for i in range(2, b + 2):
			print(s[i], end='')
	print('.', end='')
	for i in range(b + 2, e):
		print(s[i], end='')


s = str.strip(input())
a = s[0]
(d, b) = str.split(s[2:], 'e')
for _ in range(int(b)):
	if d:
		(a, d) = (a + d[0], d[1:])
	else:
		a += '0'
if not d or not int(d):
	print(int(a))
else:
	print(str.format('{}.{}', int(a), d))


from decimal import *
a = Decimal(input())
print('%d' % a) if round(a) == a else print(a)


num = input()
if num.find('.0e0') != -1:
	print(num[:num.find('.')])
else:
	(num, B) = num.split('e')
	num = list(num)
	l = []
	tens = num[:num.index('.')]
	num = num[num.index('.'):]
	for i in range(int(B)):
		if i < len(num) - 1:
			(num[i], num[i + 1]) = (num[i + 1], num[i])
		else:
			l.append(0)
	if num[-1] == '.':
		num.pop()
	final = ''.join(tens) + ''.join(num) + ''.join(map(str, l))
	print(final)


(s, b) = input().split('e')
if s.find('.') == -1:
	print(s, end='')
	print('0' * int(b))
else:
	(a, c) = s.split('.')
	c.rstrip('0')
	if a == '0' and c == '0':
		print('0')
		exit()
	b = int(b)
	if a != '0':
		print(a, end='')
	i = 0
	while b > 0:
		b -= 1
		if i < len(c):
			print(c[i], end='')
		else:
			print('0' * (b + 1))
			b = 0
		i += 1
	if i < len(c):
		if i == len(c) - 1:
			if c[i] == '0':
				exit()
		if a == '0':
			print('0', end='')
		print('.', end='')
		for j in range(i, len(c)):
			if j == len(c) - 1:
				if c[j] == '0':
					exit()
			print(c[j], end='')
	if a == '0' and c == '0':
		print('0')


inp = input()
e_ind = inp.index('e')
a = inp[:e_ind]
b = inp[e_ind + 1:]
try:
	dot = a.index('.')
	a1 = a[:dot]
	a2 = a[dot + 1:]
	if int(b) == 0:
		if int(a2) == 0:
			print(a1)
		else:
			print(a)
	elif int(b) > 0:
		if len(a2) > int(b):
			print(a1 + a2[:int(b)] + '.' + a2[int(b):])
		else:
			print(a1 + a2 + '0' * (int(b) - len(a2)))
	elif len(a1) > -int(b):
		print(a1[:int(b)] + '.' + a1[int(b):] + a2)
	else:
		print('0.' + '0' * (-int(b) - len(a1)) + a1 + a2)
except ValueError:
	if int(b) >= 0:
		print(a + '0' * int(b))
	elif len(a) > -int(b):
		print(a[:int(b)] + '.' + a[int(b):])
	else:
		print('0.' + '0' * (-int(b) - len(a)) + a)


def main():
	s = input()
	a = s.split('.')[0]
	d = s.split('.')[1].split('e')[0]
	b = int(s.split('.')[1].split('e')[1])
	if b == 0:
		res = a + '.' + d
	elif b < len(d):
		res = a + d[:b] + '.' + d[b:]
	else:
		x = b - len(d)
		zero = ''
		for i in range(b - len(d)):
			zero = zero + '0'
		res = a + d + zero
	if res[-2:] == '.0':
		res = res[:-2]
	print(res)
main()


split_by_dot = input().split('.')
split_by_e = split_by_dot[1].split('e')
a = split_by_dot[0]
d = split_by_e[0]
b = int(split_by_e[1])
D = d.lstrip('0')
decimals = len(d)
if a == '0':
	if d == '0':
		print('0')
	elif b < decimals:
		integer_part = '0' if b == 0 else d[:b - 1].lstrip('0') + d[b - 1]
		decimal_part = d[b:]
		print(integer_part, '.', decimal_part, sep='')
	else:
		print(d.lstrip('0'), '0' * (b - decimals), sep='')
elif d == '0':
	print(a, '0' * b, sep='')
elif b < decimals:
	print(a, d[:b], '.', d[b:], sep='')
else:
	print(a, d, '0' * (b - decimals), sep='')


s = str(input())
a = s[0]
d = s[2:s.find('e')]
b = int(s[s.find('e') + 1:]) + 1
a += d
while len(a) < b:
	a += '0'
a = a[:b] + '.' + a[b:]
while a[0] == '0':
	a = a[1:]
while a[-1] == '0':
	a = a[:-1]
if a[0] == '.':
	a = '0' + a
if a[-1] == '.':
	a = a[:-1]
print(a)


line = input().split('e')
p = line[0]
po = int(line[1])
pos = p.find('.')
npos = pos + po + 1
while npos > len(p):
	p = p + '0'
p = p[:pos] + p[pos + 1:npos] + '.' + p[npos:]
np = len(p) - 1
while np >= 0:
	if p[np] == '.':
		p = p[:np]
		break
	if p[np] != '0':
		break
	np -= 1
print(p)