Skip to content

Chapter 3 code runs slow for me #7

@marc9323

Description

@marc9323

Hi,
I'm really enjoying your book! I've learned a lot in just the first three chapters.

I've run into an issue however running the chapter 3 code from the book. ( sorted number list ) The benchmark test sorts 40 numbers. I'm running exactly the same code (copied from github) and it takes 63 seconds to complete. Something has to be wrong here. I'm on a Dell Laptop (Intel(R) Core(TM) i7-8550U CPU @ 1.80GHz, 1992 Mhz, 4 Core(s), 8 Logical Processor(s)).

I'm running the same code that in the book it says on page 44: "1-2 seconds to run on average". I know processors vary but this seems extreme.

Is this normal behavior? I'm new to python and benchmarking so would appreciate any clarification.
Thanks,
Marc

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions