Code execution time is slower on a better computer

I have written a simple piece of code, which reads several CSV files and combines them into one dataframe using Pandas on Python.

This is my code:



# required libraries
import time
import pandas as pd

# starting time
t0 = time.time()

datasets = []

# months and their associated number of days are packed in lists
for element in [['09', 30], ['10', 31], ['11', 3]]:
    # define the month and day
    month, days = element 
        
    # iterate the number of days in the given month
    for day in range(1, days+1):
        # the name of the file
        path = 'data' + month + '-' + "{:02d}".format(day) + '-00.csv'
        
        # name of the dataframe
        name = 'df-' + month + '-' + str(days)
        
        # read-in the CSV file
        df = pd.read_csv(path, low_memory = False)
        
        # datasets
        datasets.append(df)


# exact time after import is complete
t1 = time.time()

print('The database was created after', round(t1 - t0, 2), 'seconds \n')


# create the main Dataframe
df = pd.concat(datasets)

This code takes almost 30 seconds to run on a laptop with 16 GB of Ram and takes about 40 seconds to run on a computer with 64 GB of Ram.Both the laptop and the PC have the latest version of Pandas. I am very confused, shouldn't the pc easily outperform the laptop?

Details:

Laptop: Windows 10 - Core i5 - 1.8 GHz - 16 GB Ram

PC: Windows 7 - CPU E5 3.7 GHz - 64 GB Ram

How many English words
do you know?
Test your English vocabulary size, and measure
how many words do you know
Online Test
Powered by Examplum