EOF while reading the input error while using python

Here is the code

error is not EOF error
it is type error

at line 8
ans = int(fac_2n/fac_nfac_n(n+1))
here n is string not int so you can’t write like that

correct way to do this is

n = int(input())
fac_2n = 1
fac_n = 1
for i in range(1,2*n+1):
	fac_2n = fac_2n*i


for i in range(1,n+1):
	fac_n = fac_n*i;

ans = fac_2n/(fac_n*fac_n*(n+1))
print(ans)

convert first n to int and then proceed

https://ideone.com/aC64bY Sir , i again tried with this code but still getting EOFError

oh!!
sir please provide input
without input how it will work??
:joy: dont’ mind

Ohh!! yes sir , Actually i usually code in c++ so wasn’t aware that it gives error even for not providing input !!

But sir , all test case are passing except one , so is their any problem here !!