from itertools import accumulate



N = int(eval(input()))

A = list(map(int, input().split()))



A.sort()

a = list(accumulate(A))

answer = N



for i in range(N - 1):

    if a[i] * 2 < A[i + 1]:

        answer = N - (i + 1)



print(answer)
from itertools import accumulate





def main():

    N = int(eval(input()))

    A = list(map(int, input().split()))



    A.sort()

    a = list(accumulate(A))

    answer = N



    for i in range(N - 1):

        if a[i] * 2 < A[i + 1]:

            answer = N - (i + 1)



    print(answer)





if __name__ == '__main__':

    main()
from itertools import accumulate

N = int(eval(input()))
A = list(map(int, input().split()))
A.sort()
a = list(accumulate(A))
answer = N
for i in range(N - 1):
    if a[i] * 2 < A[i + 1]:
        answer = N - (i + 1)
print(answer)

from itertools import accumulate


def main():
    N = int(eval(input()))
    A = list(map(int, input().split()))
    A.sort()
    a = list(accumulate(A))
    answer = N
    for i in range(N - 1):
        if a[i] * 2 < A[i + 1]:
            answer = N - (i + 1)
    print(answer)


if __name__ == "__main__":
    main()

-N = int(eval(input())) -A = list(map(int, input().split())) -A.sort() -a = list(accumulate(A)) -answer = N -for i in range(N - 1): -    if a[i] * 2 < A[i + 1]: -        answer = N - (i + 1) -print(answer) + +def main(): +    N = int(eval(input())) +    A = list(map(int, input().split())) +    A.sort() +    a = list(accumulate(A)) +    answer = N +    for i in range(N - 1): +        if a[i] * 2 < A[i + 1]: +            answer = N - (i + 1) +    print(answer) + + +if __name__ == "__main__": +    main()