Question: 
Write a python function to find the first digit in factorial of a given number.


Model's Code:
def first_Digit(n):
    from math import factorial, log10
    if n == 0:
        return 1
    fact = factorial(n)
    first_digit = int(fact / (10 ** int(log10(fact))))
    return first_digit



Sample Correct Code:
import math 
def first_Digit(n) : 
    fact = 1
    for i in range(2,n + 1) : 
        fact = fact * i 
        while (fact % 10 == 0) :  
            fact = int(fact / 10) 
    while (fact >= 10) : 
        fact = int(fact / 10) 
    return math.floor(fact) 


Asserts:
assert first_Digit(5) == 1
assert first_Digit(10) == 3
assert first_Digit(7) == 5


Tests:
Test 1 of 3: PASS
Test 2 of 3: PASS
Test 3 of 3: PASS

Test 657 of 974: 492/657 (74.88584474885845%): success