Context

To close, we briefly summarize in these few pages your newly acquired exposure to programming and then describe a few aspects of the world of computing that you might encounter next. It is our hope that this information will whet your appetite to use the knowledge gained from this book for learning more about the role of computation in the world around you.

You now know how to program. Just as learning to drive an SUV is not difficult when you know how to drive a car, learning to program in a different language will not be difficult for you. Many people regularly use several different languages, for different purposes. The primitive data types, conditionals, loops, arrays, and functional abstraction described in CHAPTERS 1 AND 2 (which served programmers well for the first couple of decades of computing) and the object-oriented programming approach explored in CHAPTER 3 (which is used by modern programmers) are basic models found in many programming languages. Your skill in using them and the fundamental data types introduced in CHAPTER 4 will prepare you to cope with libraries, program development environments, and specialized applications of all sorts. You are also well positioned to appreciate the power of abstraction in designing complex systems and understanding how they work.

The study of computer science entails much more than learning to program. Now that you are familiar with programming and conversant with computing, you are well prepared to learn about not just the way in which computers operate, but also some of the outstanding intellectual achievements of the past century, some of the most important unsolved problems of our time, and their role in the evolution of the computational infrastructure that surrounds us. These topics are treated in our book Computer Science: An Interdisciplinary Approach, which consists of the first four chapters of this book and three additional chapters, one each on theory of computing, machine architecture, and logical design. These three topics are briefly described in the next three paragraphs.

Theory of computing

In contrast to the opportunities we have emphasized, fundamental limits on computation have been apparent from the beginning of the computer age and continue to play an important role in determining the kinds of problems that we can address. You may be surprised to learn that there are some problems that no computer program can solve and many other problems, which arise commonly in practice, that are thought to be too difficult to solve on any conceivable computer. Everyone who depends on computation for problem solving, creative work, or research needs to understand and respect these facts.

Machine architecture

One of our most important early promises was that we would demystify computation for you. Our hope is that Java programming is now much less mysterious to you than before you began reading this book, but a full understanding of how a computer works requires a closer look. Remarkably, virtually all computers use the same basic approach, known as von Neumann architecture, and can be programmed in a machine language that is not difficult to learn. Insights gained from writing a few programs in machine language can be valuable indeed.

Logical design

Fundamentally, programming in machine language is not much different than programming in Java, but an important reason to learn machine language is that it opens the door to see how computers are actually built. Starting with a few simple abstractions (wires that carry 0–1 values and switches controlled by wires) it is surprisingly easy to design a complete computational engine that is not so different from the one that powers your laptop or your mobile device. Learning the details is not difficult, and certainly does demystify computation.

Of course, all of the above is merely an introduction to computer science. The field has exploded in all directions, and we conclude with a list (in no particular order) of other aspects of the field that you might encounter as your exposure to computer science widens.

Programming libraries

The Java system provides extensive resources for your use. We have made extensive use of some Java libraries, such as Math and String, but have ignored most of them. One of Java’s unique features is that a great deal of information about the libraries is readily available online. If you have not yet browsed through the Java libraries, now is the time to do so. You will find that much of this code is intended for use by professional developers, but you are likely to find a number of these libraries useful for your own work. When studying a library, your attitude should be not that you need to use it, but that you can use it. When you find an API that seems useful, take advantage of it!

Programming environments

You will certainly find yourself using other programming environments besides Java in the future. Many programmers—even experienced professionals—are caught between the past, because of huge amounts of legacy code in old languages such as C, C++, and Fortran, and the future, because of the availability of modern tools like Ruby, Python, and Scala. If you want to learn Python, you might enjoy our book An Introduction to Programming in Python, a twin of this book. Again, perhaps the most important thing for you to keep in mind when using a programming language is that you do not need to use it. If some other language might better meet your needs, take advantage of it, by all means. People who insist on staying within a single programming environment, for whatever reason, are missing out on valuable opportunities.

Scientific computing

In particular, computing with numbers can be very tricky (because of accuracy and precision) so the use of libraries of mathematical functions is certainly justified. Many scientists use Fortran, an old scientific language; many others use Matlab, a language that was developed specifically for computing with matrices. The combination of good libraries and built-in matrix operations makes Matlab an attractive choice for many problems. However, since Matlab lacks support for mutable types and other modern facilities, Java is a better choice for many other problems. You can use both! The same mathematical libraries used by Matlab and Fortran programmers are accessible from Java (and through use of modern scripting languages).

Apps and cloud computing

A great deal of engagement with computing nowadays involves building and using programs intended to be run from a browser or on a mobile device, perhaps on a virtual computer in the cloud. This state of affairs is remarkable because it has vastly extended the number of people whose lives are positively affected by computing. If you find yourself engaged in this kind of computing, you are likely to be struck by the effectiveness of the basic approaches that we have discussed in this book. You can write programs that process data that is maintained elsewhere, write programs that interact with programs executing elsewhere, and take advantage of many other properties of the extensive and evolving computational infrastructure. In particular, our focus on using a scientific approach to understand performance prepares you to be able to compute on a giant scale.

Computer systems

Properties of specific computer systems once completely determined the nature and extent of problems that could be solved, but now they hardly intrude on this scope. You can still count on having a faster machine with much more memory next year at this time. Strive to keep your code machine independent, but also be prepared to learn and exploit new technologies, from GPUs to massively parallel computers and networks.

Machine learning

The field of artificial intelligence has long captured the imagination of computer scientists. The vast scale of modern computing has meant that the dreams of early researchers are being realized, to the extent that we are beginning to depend on computers to learn from their environments, whether the goal is to guide a self-driving car, lead us to the products we want to buy, or teach us what we want to learn. Harnessing computation at this level is certainly more profound than learning another set of APIs, and something that you are certain to exploit in the future.

You have certainly come a long way since you tentatively created, compiled, and ran HelloWorld, but you still have a great deal to learn. Keep programming, and keep learning about programming environments, scientific computing, apps and cloud computing, computer systems, theory of computing, and machine learning. By doing so, you will open opportunities for yourself that people who do not program cannot even conceive. Perhaps even more significant, as we have hinted throughout the book, is the reality that computation is playing an ever-increasing role in our understanding of nature, from genomics to molecular dynamics to astrophysics. Further study of the fascinating world of computer science is certain to pay dividends, whatever the future holds for you.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.15.229.111