- Java 9 Data Structures and Algorithms
- Debasish Ray Chawdhuri
- 333字
- 2021-07-02 23:26:42
Chapter 1. Why Bother? – Basic
Since you already know Java, you have of course written a few programs, which means you have written algorithms. "Well then, what is it?" you might ask. An algorithm is a list of well-defined steps that can be followed by a processor mechanically, or without involving any sort of intelligence, which would produce a desired output in a finite amount of time. Well, that's a long sentence. In simpler words, an algorithm is just an unambiguous list of steps to get something done. It kind of sounds like we are talking about a program. Isn't a program also a list of instructions that we give the computer to follow, in order to get a desired result? Yes it is, and that means an algorithm is really just a program. Well not really, but almost. An algorithm is a program without the details of the particular programming language that we are coding it in. It is the basic idea of the program; think of it as an abstraction of a program where you don't need to bother about the program's syntactic details.
Well, since we already know about programming, and an algorithm is just a program, we are done with it, right? Not really. There is a lot to learn about programs and algorithms, that is, how to write an algorithm to achieve a particular goal. There are, of course, in general, many ways to solve a particular problem and not all ways may be equal. One way may be faster than another, and that is a very important thing about algorithms. When we study algorithms, the time it takes to execute is of utmost importance. In fact, it is the second most important thing about them, the first one being their correctness.
In this chapter, we will take a deeper look into the following ideas:
- Measuring the performance of an algorithm
- Asymptotic complexity
- Why asymptotic complexity matters
- Why an explicit study of algorithms is important
- JavaScript前端開發(fā)模塊化教程
- SEO智慧
- 游戲程序設計教程
- Xamarin.Forms Projects
- Scala編程實戰(zhàn)(原書第2版)
- BIM概論及Revit精講
- Building RESTful Python Web Services
- Web前端開發(fā)技術:HTML、CSS、JavaScript
- ROS機器人編程實戰(zhàn)
- Spark技術內(nèi)幕:深入解析Spark內(nèi)核架構(gòu)設計與實現(xiàn)原理
- 系統(tǒng)分析師UML用例實戰(zhàn)
- 計算機軟件項目實訓指導
- Appcelerator Titanium Smartphone App Development Cookbook
- PhoneGap 3.x Mobile Application Development Hotshot
- Swift編程實戰(zhàn):iOS應用開發(fā)實例及完整解決方案