qyliang/CodeNanoFix huggingface dataset:
Buggy code:
n = int(input())
lis=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47]
li=[]
a=0
b=0
c=0
d=0
e=0
for i in range(15):
    p=n
    q=0
    while(p>0):
        q+=p//lis[i]
        p=p//lis[i]
    if q>=74:
        e+=1
    if q>=24:
        print(lis[i])
        a+=1
    if q>=14:
        print(lis[i])
        b+=1
    if q>=4:
        print(lis[i])
        c+=1
    if q>=2:
        print(lis[i])
        d+=1
ans=a*(d-1)+b*(c-1)+(c*(c-1))//2*(d-2)+e
print(ans)

Fixed code:
n = int(input())
lis=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47]
li=[]
a=0
b=0
c=0
d=0
e=0
for i in range(15):
    p=n
    q=0
    while(p>0):
        q+=p//lis[i]
        p=p//lis[i]
    if q>=74:
        e+=1
    if q>=24:
        a+=1
    if q>=14:
        b+=1
    if q>=4:
        c+=1
    if q>=2:
        d+=1
ans=a*(d-1)+b*(c-1)+(c*(c-1))//2*(d-2)+e
print(ans)
Buggy code:
def factorize(n):
    t = n
    ret = []
    for i in range(2, int(n ** 0.5) + 1):
        while (t % i == 0):
            t //= i
            ret.append(i)
    if t > 1:
        ret.append(t)
    return ret


N = int(input())
d = []
for n in range(1, N + 1):
    d.extend(factorize(n))
d.sort()
ds = set(d)
dn = [0] * 101
for c in ds:
    dn[c] = d.count(c)
ans = 0
t = []
for i in ds:
    for j in ds:
        if i == j:
            continue
        for k in ds:
            if i == k or j == k:
                continue
            for l in [0, 2, 4, 14, 24]:
                if l <= dn[i]:
                    for m in [0, 2, 4, 14, 24]:
                        if m <= dn[j]:
                            for n in [0, 2, 4, 14, 24]:
                                if n <= dn[k]:
                                    c = (l + 1) * (m + 1) * (n + 1)
                                    if c == 75:
                                        e = i ** l * j ** m * k ** n
                                        if not e in t:
                                            ans += 1
                                            t += [e]
print(ans)

Fixed code:
def factorize(n):
    t = n
    ret = []
    for i in range(2, int(n ** 0.5) + 1):
        while (t % i == 0):
            t //= i
            ret.append(i)
    if t > 1:
        ret.append(t)
    return ret


N = int(input())
d = []
for n in range(1, N + 1):
    d.extend(factorize(n))
d.sort()
ds = set(d)
dn = [0] * 101
for c in ds:
    dn[c] = d.count(c)
ans = 0
t = []
for i in ds:
    for j in ds:
        if i == j:
            continue
        for k in ds:
            if i == k or j == k:
                continue
            for l in [0, 2, 4, 14, 24, 74]:
                if l <= dn[i]:
                    for m in [0, 2, 4, 14, 24, 74]:
                        if m <= dn[j]:
                            for n in [0, 2, 4, 14, 24, 74]:
                                if n <= dn[k]:
                                    c = (l + 1) * (m + 1) * (n + 1)
                                    if c == 75:
                                        e = i ** l * j ** m * k ** n
                                        if not e in t:
                                            ans += 1
                                            t += [e]
print(ans)
Buggy code:
from math import factorial
from math import sqrt
from math import ceil
from itertools import permutations
from heapq import *
from collections import defaultdict
from copy import deepcopy
from math import log

N=int(input())
def nCr(n,r):
    if n<r:
        return 0
    a=factorial(n)
    b=factorial(n-r)
    c=factorial(r)
    return a//(b*c)
f=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47]
a=0
b=0
c=0
d=0
e=0
for F in f:
    s=sum([N/(F**i) for i in range(1,7)])
    if s>=74:
        e+=1
    elif s>=24:
        d+=1
    elif s>=14:
        c+=1
    elif s>=4:
        b+=1
    elif s>=2:
        a+=1
print(nCr(b+c+d+e,2)*a+nCr(b+c+d+e,3)*3+(c+d+e)*(b+c+d+e-1)+(e+d)*(a+b+c+d+e-1)+e)


Fixed code:
from math import factorial
from math import sqrt
from math import ceil
from itertools import permutations
from heapq import *
from collections import defaultdict
from copy import deepcopy
from math import log

N=int(input())
def nCr(n,r):
    if n<r:
        return 0
    a=factorial(n)
    b=factorial(n-r)
    c=factorial(r)
    return a//(b*c)
f=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47]
a=0
b=0
c=0
d=0
e=0
for F in f:
    s=sum([(N//(F**i)) for i in range(1,7)])
    if s>=74:
        e+=1
    elif s>=24:
        d+=1
    elif s>=14:
        c+=1
    elif s>=4:
        b+=1
    elif s>=2:
        a+=1

print(nCr(b+c+d+e,2)*a+nCr(b+c+d+e,3)*3+(c+d+e)*(max(b+c+d+e-1,0))+(e+d)*(max(0,a+b+c+d+e-1))+e)
Buggy code:
N=int(input())
div=[0]*(N+1)

for i in range(1,N+1):
    j=2
    while i!=1:
        if i%j==0:
            i//=j
            div[j]+=1
        else: j+=1

print(div)

a,b,c,d,e=0,0,0,0,0
for i in range(N+1):
    if div[i]>74: e+=1
    if div[i]>24:
        a+=1
        b+=1
        c+=1
        d+=1
    elif div[i]>14: 
        a+=1
        b+=1
        c+=1
    elif div[i]>=4:
        a+=1
        b+=1
    elif div[i]>=2:
        a+=1



print(a,b,c,d,e)

if a<3 or b<2: print(0)
else:
    ans=b*(b-1)*(a-2)//2
    ans+=d*(a-1)
    ans+=c*(b-1)
    ans+=e
    print(ans)

Fixed code:
N=int(input())
div=[0]*(N+1)

for i in range(1,N+1):
    j=2
    while i!=1:
        if i%j==0:
            i//=j
            div[j]+=1
        else: j+=1

a,b,c,d,e=0,0,0,0,0
for i in range(N+1):
    if div[i]>=74:
        a+=1
        b+=1
        c+=1
        d+=1
        e+=1
    elif div[i]>=24:
        a+=1
        b+=1
        c+=1
        d+=1
    elif div[i]>=14: 
        a+=1
        b+=1
        c+=1
    elif div[i]>=4:
        a+=1
        b+=1
    elif div[i]>=2:
        a+=1

if a<3 or b<2: print(0)
else:
    ans=b*(b-1)*(a-2)//2
    ans+=d*(a-1)
    ans+=c*(b-1)
    ans+=e
    print(ans)
Buggy code:
N = int(input())

elem = [0 for _ in range(N+1)]

for i in range(1, N+1):
    cur = i
    for j in range(1, i+1):
        while cur % j == 0:
            elem[j] += 1
            cur //= j

def num(m):
    return len(list(filter(lambda x: x >= m-1, elem)))

print(num(75)  + num(25)*(num(3)-1) + num(15)*(num(3)-1) + num(5)*(num(5)-1)*(num(3)-2) // 2)


Fixed code:

N = int(input())

num = [0 for _ in range(N+1)]
for i in range(2, N+1):
    cur = i
    for j in range(2, i+1):
        while cur % j == 0:
            num[j] += 1
            cur //= j


def Count(m):
    return len(list(filter(lambda x: x >= m - 1, num)))


ans = Count(75) + (Count(3)-1)*Count(25) + Count(15) * (Count(5)-1)\
      + Count(5)*(Count(5)-1)*(Count(3)-2)//2
print(ans)
Buggy code:
prime=[2,3,5,7,11,13,17,19,23,29,31]
s=[0 for i in range(11)]
N=int(input())
for i in range(11):
  j=1
  while N//(prime[i]**j)>0:
    s[i]+=N//(prime[i]**j)
    j+=1
o3,o5,o15,o25,o75=0,0,0,0,0
for item in s:
  if item>=2:
    o3+=1
    if item>=4:
      o5+=1
      if item>=14:
        o15+=1
        if item>=24:
          o25+=1
          if item>=74:
            o75+=1
ans=[0,0,0,0]
if o75>0:
  ans[0]+=1
if o25>0:
  ans[1]+=o25*(o3-1)
if o15>0:
  ans[2]+=o15*(o5-1)
if o5>1 and o3>2:
  ans[3]+=o5*(o5-1)*(o3-2)
print(sum(ans))


Fixed code:
prime=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47]
s=[0 for i in range(15)]
N=int(input())
for i in range(15):
  j=1
  while N//(prime[i]**j)>0:
    s[i]+=N//(prime[i]**j)
    j+=1
o3,o5,o15,o25,o75=0,0,0,0,0
for item in s:
  if item>=2:
    o3+=1
    if item>=4:
      o5+=1
      if item>=14:
        o15+=1
        if item>=24:
          o25+=1
          if item>=74:
            o75+=1
ans=[0,0,0,0]
if o75>0:
  ans[0]+=1
if o25>0:
  ans[1]+=o25*(o3-1)
if o15>0:
  ans[2]+=o15*(o5-1)
if o5>1 and o3>2:
  ans[3]+=o5*(o5-1)//2*(o3-2)
print(sum(ans))
Buggy code:
N=int(input())

def IsPrime(A):
    prime=[2]
    for a in range(3,A+1):
        for p in prime:
            if a%p==0:
                break
        else:
            prime.append(a)
    return prime


prime=IsPrime(N)
#print(prime)
pcount={}
for p in prime:
    pcount[p]=0
for nn in range(2,N+1):
    for p in prime:
        n=nn
        if n<p:
            break
        while n%p==0:
            n//=p
            pcount[p]+=1
#print(pcount)
mcount={}
for i in [75,25,15,5,3]:
    mcount[i]=0
for p in prime:
    for i in [75,25,15,5,3]:
        if pcount[p]>=i-1:
            mcount[i]+=1
print(mcount)
print(mcount[75]+\
        mcount[25]*(mcount[3]-1)+\
        mcount[15]*(mcount[5]-1)+\
        mcount[5]*(mcount[5]-1)//2*(mcount[3]-2))
#75/25*3/15*5/5*5*3


Fixed code:
N=int(input())

def IsPrime(A):
    prime=[2]
    for a in range(3,A+1):
        for p in prime:
            if a%p==0:
                break
        else:
            prime.append(a)
    return prime


prime=IsPrime(N)
#print(prime)
pcount={}
for p in prime:
    pcount[p]=0
for nn in range(2,N+1):
    for p in prime:
        n=nn
        if n<p:
            break
        while n%p==0:
            n//=p
            pcount[p]+=1
#print(pcount)
mcount={}
for i in [75,25,15,5,3]:
    mcount[i]=0
for p in prime:
    for i in [75,25,15,5,3]:
        if pcount[p]>=i-1:
            mcount[i]+=1
#print(mcount)
print(mcount[75]+\
        mcount[25]*(mcount[3]-1)+\
        mcount[15]*(mcount[5]-1)+\
        mcount[5]*(mcount[5]-1)//2*(mcount[3]-2))
#75/25*3/15*5/5*5*3
Buggy code:
def isprime(n):
    if(n<2):
        return False
    for i in range(2,n):
        if(n%i==0):
            return False
    return True

def primelist(n):
    return [i for i in range(n) if isprime(i)]

def factor(n):
    f = {}
    while(n > 1):
        for p in primelist(n+1):
            if(n % p == 0):
                f[p] = f.get(p, 0) + 1
                n //= p
    return f

def factorfactorial(n):
    f = {}
    for i in range(1,n+1):
        fi = factor(i)
        for k, v in fi.items():
            f[k] = f.get(k,0) + v
    return f

# 75 = 3*5*5 = 3*25 = 5*15 
n = int(input())
f = factorfactorial(n)

print(f)
cnt = 0

# print(primelist(n+1))
for i in primelist(n+1):
    if(f[i]>75):
        cnt += 1
    for j in primelist(n+1):
        if(i==j):
            continue
        if(f[i]>=25-1 and f[j]>=3-1):
            cnt += 1
        if(f[i]>=15-1 and f[j]>=5-1):
            cnt += 1
        if(i > j):
            for k in primelist(n+1):
                if k in [i,j]:
                    continue
                if(f[i]>=5-1 and f[j]>=5-1 and f[k]>=3-1):
                    cnt += 1



print(cnt)


Fixed code:
def isprime(n):
    if(n<2):
        return False
    for i in range(2,n):
        if(n%i==0):
            return False
    return True

def primelist(n):
    return [i for i in range(n) if isprime(i)]

def factor(n):
    f = {}
    while(n > 1):
        for p in primelist(n+1):
            if(n % p == 0):
                f[p] = f.get(p, 0) + 1
                n //= p
    return f

def factorfactorial(n):
    f = {}
    for i in range(1,n+1):
        fi = factor(i)
        for k, v in fi.items():
            f[k] = f.get(k,0) + v
    return f

# 75 = 3*5*5 = 3*25 = 5*15 
n = int(input())
f = factorfactorial(n)

# print(f)
cnt = 0

for i in f.keys():
    if(f[i]>=75-1):
        cnt += 1
    for j in primelist(n+1):
        if(i==j):
            continue
        if(f[i]>=25-1 and f[j]>=3-1):
            cnt += 1
        if(f[i]>=15-1 and f[j]>=5-1):
            cnt += 1
        if(i > j):
            for k in primelist(n+1):
                if k in [i,j]:
                    continue
                if(f[i]>=5-1 and f[j]>=5-1 and f[k]>=3-1):
                    cnt += 1



print(cnt)
Buggy code:
def era(n):
    table = [0] * (n + 1)
    prime_list = []
    
    for i in range(2, n + 1):
        if table[i] == 0:
            prime_list.append(i)
            for j in range(2*i, n + 1, i):
                table[j] = 1
    
    return prime_list

def f(n):
    cnt = 0
    for i in data:
        if i[1] >= n-1:
            cnt += 1
    return cnt
 
N = int(input())
s = era(N)
data = []
 
for i in s:
    k = i
    c = 0
    while N // k >= 1:
        c += N // k
        k = k*i
        print(c,k)
 
    data.append([i,c])
 

print(f(75)+f(15)*(f(5)-1)+f(25)*(f(3)-1)+f(5)*(f(5)-1)*(f(3)-2)//2)

Fixed code:
def era(n):
    table = [0] * (n + 1)
    prime_list = []
    
    for i in range(2, n + 1):
        if table[i] == 0:
            prime_list.append(i)
            for j in range(2*i, n + 1, i):
                table[j] = 1
    
    return prime_list

def f(n):
    cnt = 0
    for i in data:
        if i[1] >= n-1:
            cnt += 1
    return cnt
 
N = int(input())
s = era(N)
data = []
 
for i in s:
    k = i
    c = 0
    while N // k >= 1:
        c += N // k
        k = k*i
 
    data.append([i,c])
 

print(f(75)+f(15)*(f(5)-1)+f(25)*(f(3)-1)+f(5)*(f(5)-1)*(f(3)-2)//2)
Buggy code:
from math import factorial
n=int(input())

def prime_decomposition(n):
  i = 2
  table = []
  while i * i <= n:
    while n % i == 0:
      n /= i
      table.append(i)
    i += 1
  if n > 1:
    table.append(int(n))
  return table

s=[]

for i in range(1,n+1):
  s=s+(prime_decomposition(i))

count2=0
count4=0
sumation=0
for i in range(1,n+1):
  if s.count(i)==2 or s.count(i)==3:
    count2 +=1
  elif s.count(i) >3:
    count4 +=1

sumation += count4*(count4-1)/2*(count2+count4-2)
print(sumation)

count2=0
count4=0
for i in range(1,n+1):
  if s.count(i)>=24:
    count2 +=1
  elif s.count(i) >=2:
    count4 +=1
    
sumation += count2*(count2+count4-1)
print(sumation)

count2=0
count4=0
for i in range(1,n+1):
  if s.count(i)>=14:
    count2 +=1
  elif s.count(i) >=4:
    count4 +=1
    
sumation += count2*(count2+count4-1)
print(sumation)

count2=0
count4=0
for i in range(1,n+1):
  if s.count(i)>=74:
    count2 +=1
    
sumation += count2

print(int(sumation))



Fixed code:
from math import factorial
n=int(input())

def prime_decomposition(n):
  i = 2
  table = []
  while i * i <= n:
    while n % i == 0:
      n /= i
      table.append(i)
    i += 1
  if n > 1:
    table.append(int(n))
  return table

s=[]

for i in range(1,n+1):
  s=s+(prime_decomposition(i))

count2=0
count4=0
sumation=0
for i in range(1,n+1):
  if s.count(i)==2 or s.count(i)==3:
    count2 +=1
  elif s.count(i) >3:
    count4 +=1

sumation += count4*(count4-1)/2*(count2+count4-2)

count2=0
count4=0
for i in range(1,n+1):
  if s.count(i)>=24:
    count2 +=1
  elif s.count(i) >=2:
    count4 +=1
    
sumation += count2*(count2+count4-1)

count2=0
count4=0
for i in range(1,n+1):
  if s.count(i)>=14:
    count2 +=1
  elif s.count(i) >=4:
    count4 +=1
    
sumation += count2*(count2+count4-1)

count2=0
count4=0
for i in range(1,n+1):
  if s.count(i)>=74:
    count2 +=1
    
sumation += count2

print(int(sumation))
Buggy code:
def check(m, e):
    return len(list(filter(lambda x: x >= m - 1, e)))


def check_1(m, e):
    return list(filter(lambda x: x >= m - 1, e))


def main():
    N = int(input())
    e = [0] * (N + 1)

    for i in range(2, N + 1):
        ii = i
        for j in range(2, i + 1):
            while ii % j == 0:
                e[j] += 1
                ii //= j

    print(check_1(25, e), check_1(3, e))
    print(check(75, e) +
          check(25, e) * (check(3, e) - 1) +
          check(15, e) * (check(5, e) - 1) +
          check(5, e) * (check(5, e) - 1) * (check(3, e) - 2) // 2)


if __name__ == '__main__':
    main()


Fixed code:
def check(m, e):
    return len(list(filter(lambda x: x >= m - 1, e)))


def main():
    N = int(input())
    e = [0] * (N + 1)

    for i in range(2, N + 1):
        ii = i
        for j in range(2, i + 1):
            while ii % j == 0:
                e[j] += 1
                ii //= j

    print(check(75, e) +
          check(25, e) * (check(3, e) - 1) +
          check(15, e) * (check(5, e) - 1) +
          check(5, e) * (check(5, e) - 1) * (check(3, e) - 2) // 2)


if __name__ == '__main__':
    main()
Buggy code:
n = int(input())
yakusu = [0]*105
for num in range(1,n+1):
    for i in range(2,n+1):
        while(num%i==0):
            yakusu[i] += 1
            num//=i
        if num == 1:
            break

over = [0]*100
for i in range(1,n+1):
    if(yakusu[i] >= 2):
        over[2]+=1
    if(yakusu[i] >= 4):
        over[4]+=1
    if(yakusu[i] >= 14):
        over[14]+=1
    if(yakusu[i] >= 24):
        over[24]+=1

ans = over[14]*(over[4]-1) + over[24]*(over[2]-1) + over[4]*(over[4]-1)*(over[2]-2)//2
print(ans)

Fixed code:
n = int(input())
yakusu = [0]*105
for num in range(1,n+1):
    for i in range(2,n+1):
        while(num%i==0):
            yakusu[i] += 1
            num//=i
        if num == 1:
            break

over = [0]*100
for i in range(1,n+1):
    if(yakusu[i] >= 2):
        over[2]+=1
    if(yakusu[i] >= 4):
        over[4]+=1
    if(yakusu[i] >= 14):
        over[14]+=1
    if(yakusu[i] >= 24):
        over[24]+=1
    if(yakusu[i] >= 74):
        over[74]+=1

ans = over[74]+over[14]*(over[4]-1) + over[24]*(over[2]-1) + over[4]*(over[4]-1)*(over[2]-2)//2
print(ans)
Buggy code:
import math

SO=[0 for i in range(101)]

N=int(input())
for i in range(2,N+1):
    NUM=i
    for j in range(2,100):
        while NUM%j==0:
            SO[j]+=1
            NUM=NUM/j
A74=0
A24=0
A14=0
A04=0
A02=0
for j in range(len(SO)):
    if SO[j]>=74:
        A74+=1
    if SO[j]>=24:
        A24+=1
    if SO[j]>=14:
        A14+=1
    if SO[j]>=4:
        A04+=1
    if SO[j]>=2:
        A02+=1
#print(SO)
def combinations_count(n, r):
    return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

#74
ans=A74
#3*5*5
if A04>=2:
    ans=min((A02-2),0)*combinations_count(A04,2)
#3*25
ans+=min((A02-1),0)*A24
#5*15
ans+=min((A04-1),0)*A14


print(ans)

Fixed code:
import math

SO=[0 for i in range(101)]

N=int(input())
for i in range(2,N+1):
    NUM=i
    for j in range(2,100):
        while NUM%j==0:
            SO[j]+=1
            NUM=NUM/j
A74=0
A24=0
A14=0
A04=0
A02=0
for j in range(len(SO)):
    if SO[j]>=74:
        A74+=1
    if SO[j]>=24:
        A24+=1
    if SO[j]>=14:
        A14+=1
    if SO[j]>=4:
        A04+=1
    if SO[j]>=2:
        A02+=1
#print(SO)
def combinations_count(n, r):
    return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

#74
ans=A74
#3*5*5
if A04>=2:
    ans+=(A02-2)*combinations_count(A04,2)
#3*25
ans+=(A02-1)*A24
#5*15
ans+=(A04-1)*A14


print(ans)
Buggy code:
N = int(input()) e=[0]*(N+1)
for i in range(2, N+1):
    cur = i
    for j in range(2, i+1):
        while cur % j == 0:
            e[j] += 1
cur //= j
def num(m):
    return len(list(filter(lambda x: x >= m-1, e)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1)
    + num(5) * (num(5) - 1) * (num(3) - 2) // 2)

Fixed code:
n = int(input())
e = [0 for i in range(n + 1)]

for i in range(2, n + 1):
    cur = i
    for j in range(2, i + 1):
        while cur % j == 0:
            e[j] += 1
            cur //= j

def num(m):
    return len(list(filter(lambda x: x >= m - 1, e)))

print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)
Buggy code:
N = int(input())

n = [0]*(N+1)
for i in range(2, N+1):
    for j in range(2, i+1):
        while i%j == 0:
            i//=j
            n[j] += 1

def num(m):
return len(list(filter(lambda x: x>=m-1, n)))

print(num(75)+num(25)*(num(3)-1)+num(15)*(num(5)-1)14+num(5)*(num(5)-1)*(num(3)-2)//2)

Fixed code:
N = int(input())

factor = [0 for _ in range(N + 1)]

for i in range(2, N + 1):
    n = i
    for j in range(2, i + 1):
        while n % j == 0:
            factor[j] += 1
            n //= j


def num(m):
    return len(list(filter(lambda x: x >= m - 1, factor)))

ans = num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2
print(ans)
Buggy code:
def D():
    N = int(input())
    tmplist = [0 for i in range(N + 1)]
    for i in range(1, N + 1):
        key = i
        for j in range(2, key + 1):
            while i % j == 0:
                tmplist[j] += 1
                i /= j
    ans = 0
    anslist = []
    for p in range(N + 1):
        if tmplist[p] + 1 >= 75:
            anslist.append(pow(p, 74))
        for q in range(N + 1):
            if p != q and tmplist[p] + 1 >= 25 and tmplist[q] + 1 >= 3:
                anslist.append(pow(p, 24) * pow(q, 2))
            if p != q and tmplist[p] + 1 >= 15 and tmplist[q] + 1 >= 5:
                anslist.append(pow(p, 14) * pow(q, 4))
            for r in range(N + 1):
                if p != q and q != r and r != p and tmplist[p] + 1 >= 5 and tmplist[q] + 1 >= 5 and tmplist[r] + 1 >= 3:
                    anslist.append(pow(p, 4) * pow(q, 4) * pow(r, 2))
    anslist.sort()
    ans = 1
    for i in range(1, len(anslist)):
        if anslist[i] != anslist[i - 1]:
            ans += 1
    print(ans)

D()

Fixed code:
def D():
    N = int(input())
    tmplist = [0 for i in range(N + 1)]
    for i in range(1, N + 1):
        key = i
        for j in range(2, key + 1):
            while i % j == 0:
                tmplist[j] += 1
                i /= j
    ans = 0
    anslist = []
    for p in range(N + 1):
        if tmplist[p] + 1 >= 75:
            anslist.append(pow(p, 74))
        for q in range(N + 1):
            if p != q and tmplist[p] + 1 >= 25 and tmplist[q] + 1 >= 3:
                anslist.append(pow(p, 24) * pow(q, 2))
            if p != q and tmplist[p] + 1 >= 15 and tmplist[q] + 1 >= 5:
                anslist.append(pow(p, 14) * pow(q, 4))
            for r in range(N + 1):
                if p != q and q != r and r != p and tmplist[p] + 1 >= 5 and tmplist[q] + 1 >= 5 and tmplist[r] + 1 >= 3:
                    anslist.append(pow(p, 4) * pow(q, 4) * pow(r, 2))
    anslist.sort()
    ans = 1
    for i in range(1, len(anslist)):
        if anslist[i] != anslist[i - 1]:
            ans += 1
    if len(anslist) == 0:
        ans = 0
    print(ans)

D()
Buggy code:
from collections import Counter
import math
def P(n, r):
  return math.factorial(n)//math.factorial(n-r)
def C(n, r):
  return P(n, r)//math.factorial(r)
n=int(input())
L=[]
for j in range(2,n+1):
    I=j
    s=0
    R=int(I)
    while s==0:
        for i in range(2,R+1):
            if I%i==0:
                I=I/i
                if I==1:
                    s=1
                L.append(i)
                break
c=Counter(L)
c=[0 for i in range(100)]
for i,j in c.most_common():
  c[j]+=1
 
s=0
s+=sum(c[4:])*(sum(c[4:])-1)*sum(c[2:]-2)//2
s+=sum(c[14:])*(sum(c[4:])-1)
s+=sum(c[24:])*(sum(c[2:])-1)
s+=sum(c[74:])
print(s)

Fixed code:
from collections import Counter
import math
def P(n, r):
  return math.factorial(n)//math.factorial(n-r)
def C(n, r):
  return P(n, r)//math.factorial(r)
n=int(input())
L=[]
for j in range(2,n+1):
    I=j
    s=0
    R=int(I)
    while s==0:
        for i in range(2,R+1):
            if I%i==0:
                I=I/i
                if I==1:
                    s=1
                L.append(i)
                break
C=Counter(L)
c=[0 for i in range(100)]
for i,j in C.most_common():
  c[j]+=1
 
s=0
s+=sum(c[4:])*(sum(c[4:])-1)*(sum(c[2:])-2)//2
s+=sum(c[14:])*(sum(c[4:])-1)
s+=sum(c[24:])*(sum(c[2:])-1)
s+=sum(c[74:])
print(s)
Buggy code:
from collections import Counter as c

def fact(n):
    d=[]
    for i in range(2,int(n**0.5)+2):
        while n%i==0:
            n//=i
            d.append(i)
    if n!=1:d.append(n)
    return c(d)

n=int(input())
d=c()
for i in range(1,n+1):
    d+=fact(i)

f=lambda n,x:sum(1 for i in p(d.values(),n) if all(map(lambda x,y:x>=y,i,x)))
print(f(3,(2,4,4))//2+f(2,(2,24))+f(2,(4,14))+f(1,(74,)))

Fixed code:
from collections import Counter as c
from itertools import permutations as p

def fact(n):
    d=[]
    for i in range(2,int(n**0.5)+2):
        while n%i==0:
            n//=i
            d.append(i)
    if n!=1:d.append(n)
    return c(d)

n=int(input())
d=c()
for i in range(1,n+1):
    d+=fact(i)

f=lambda n,x:sum(1 for i in p(d.values(),n) if all(map(lambda x,y:x>=y,i,x)))
print(f(3,(2,4,4))//2+f(2,(2,24))+f(2,(4,14))+f(1,(74,)))