What is the big deal about Big-O notation in computer science?

前端 未结 14 578
广开言路
广开言路 2021-01-31 11:30

How would Big-O notation help in my day-to-day C# programming? Is it just an academic exercise?

相关标签:
14条回答
  • 2021-01-31 12:00

    Yeah, it is just an "academic exercise". An be assured, as long as some stupid academics do such exercises you will be able to do a good programming job from day to day :-)

    By the way, if these academics don't look at lambda calculus, graph theory, automatas, turing machines or something else, they find their shortes path to have dinner with philosophers.

    For further information, have a look at a good academic book or at the excellent answers above ...

    0 讨论(0)
  • 2021-01-31 12:05

    Big-O is important in algorithm design more than day to day hacks. Generally you don't need to know Big-O unless you are doing work on a lot of data (ie if you need to sort an array that is 10,000 elements, not 10). In a lot of cases, their are libraries that handle the tricky stuff for you (like a built in sort function), but in some cases you need to do it yourself.

    Bottom line is that Big-O is fairly easy to learn, so just learn it. It will help you in a bunch of cases.

    0 讨论(0)
提交回复
热议问题