青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品

天行健 君子當自強而不息

C++, An Overview

There are two primary aspects to the programs we write

  1. A collection of algorithms (that is, the programmed instructions to solve a particular task)

  2. A collection of data against which the algorithms are run to provide each unique solution

These two primary program aspects, algorithms and data, have remained invariant throughout the short history of computing. What has evolved is the relationship between them. This relationship is spoken of as a programming paradigm.

In the procedural programming paradigm, a problem is directly modeled by a set of algorithms. A check-out/check-in system for loan materials of a public library, such as books, videos, and so on, is represented as a series of procedures, the two central procedures being the checking-out and checking-in of library materials. The data is stored separately, accessed either at a global location or by being passed into the procedures. Three prominent procedural languages are FORTRAN, C, and Pascal. C++ also supports procedural programming. Individual procedures, such as check_in(), check_out(), overdue(), fine(), and so on, are referred to as functions. Part III, Procedural-Based Programming, focuses on the support C++ provides for the procedural programming paradigm, with an emphasis on functions, function templates, and generic algorithms.

In the 1970s, the focus of program design shifted from the procedural paradigm to that of abstract data types (now generally referred to as object-based programming). In this paradigm, a problem is modeled by a set of data abstractions. In C++ we refer to these abstractions as classes. Our library check-out system, for example, under this paradigm is represented as the interaction between object instances of classes such as Book, Borrower, DueDate (an aspect of Time), and the inevitable Fine (an aspect of Money), representing the library abstractions. The algorithms associated with each class are referred to as the class's public interface. The data is privately stored within each object; access of the data is hidden from the general program. Three programming languages that support the abstract data type paradigm are CLU, Ada, and Modula-2. Part IV, Object-Based Programming, illustrates and discusses the support C++ provides for the abstract data type programming paradigm.

Object-oriented programming extends abstract data types through the mechanisms of inheritance (a "reuse" of an existing implementation) and dynamic binding (a reuse of an existing public interface). Special type/subtype relationships between previously independent types are now provided. A book, videotape, recording, and children's puppet are each a kind of library material, although each has its own check-out and check-in policy. The shared public interface and private data are placed in an abstract LibraryMaterial class. Each specific library material class inherits the shared behavior from the LibraryMaterial abstract class and need provide only the algorithms and data that support its behavior. Three prominent languages supporting the object-oriented paradigm are Simula, Smalltalk, and Java. Part V, Object-Oriented Programming, focuses on the support C++ provides for the object-oriented programming paradigm.

C++ is a multiparadigm language. Although we think of it primarily as an object-oriented language, it also provides support for procedural and object-based programming. The benefit is that we are able to provide a solution best suited to the problem ?in practice, no one paradigm represents a best solution to every problem. The drawback is that it makes for a larger and more complicated language.

In Part I, we present a quick tour of the entire C++ language. One reason for this is to provide a first introduction to the language features so that we can more freely reference aspects of the language before we fully treat them. For example, we don't look at classes in detail until Chapter 13, but if we waited until then to mention classes we would end up presenting a great many unrepresentative and largely irrelevant program examples.

A second reason for providing a breadth-first tour of the language is aesthetic. Unless you are exposed to the beauty and complexity of a Beethoven sonata or the exhilaration of a Scott Joplin rag, it is easy to become alternately impatient and bored with the apparent irrelevant detail of sharps, flats, octaves, and chords; but until those details are mastered, making music remains largely beyond our means. Much the same holds true with programming. Stepping through the maze of operator precedence or rules governing the standard arithmetic conversions is a necessary but necessarily tedious foundation to mastering programming in C++.

Chapter 1 provides a first introduction to the basic elements of the language: the built-in data types, variables, expressions, statements, and functions. It looks at a minimum legal C++ program, discusses the process of compiling our programs, briefly walks through the preprocessor, and takes a first look at support for input and output. It presents a number of simple but complete C++ programs that the reader is encouraged to compile and execute.

In Chapter 2, we walk through a procedural program, an object-based program, and then an object-oriented program implementation of an array ?that is, a numbered collection of elements of the same type. We then compare our array abstraction with the C++ standard library vector class and take a first look at the standard library generic algorithms. Along the way, we motivate and take a first peek at C++'s support for exception handling, templates, and namespaces. In effect, the entire language is introduced, although many of the details are deferred until later in the text.

Some readers may find portions of Chapter 2 rough going. Material is presented without the full explanation normally expected of a primer (the explanation is provided in subsequent chapters). If you should find yourself feeling overwhelmed or impatient at the level of detail, we recommend that you skim through or skip that portion, returning to it later when the material is more familiar. In Chapter 3, we begin the more traditional narrative pace, and the reader uncomfortable with Chapter 2 is recommended to start there.

posted on 2007-10-17 19:43 lovedday 閱讀(842) 評論(0)  編輯 收藏 引用 所屬分類: ▲ C++ Primer

公告

導航

統計

常用鏈接

隨筆分類(178)

3D游戲編程相關鏈接

搜索

最新評論

青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品
  • <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            亚洲国产欧美日韩精品| 欧美日韩蜜桃| 亚洲成色精品| 欧美激情成人在线| 欧美jizz19性欧美| 91久久国产精品91久久性色| 亚洲国产精品嫩草影院| 日韩手机在线导航| 亚洲在线黄色| 久久久久久久久久久久久女国产乱| 久久av老司机精品网站导航| 久久久久国内| 欧美精品三级日韩久久| 欧美视频免费在线观看| 国产亚洲精品久久飘花| 伊人久久大香线蕉综合热线| 亚洲精品中文字| 欧美一区二区免费视频| 男女激情久久| 夜夜嗨av色综合久久久综合网 | 国产亚洲电影| 在线观看av一区| 亚洲小视频在线观看| 久久三级福利| 一本色道久久综合亚洲精品不 | 亚洲深爱激情| 久久午夜电影| 国产精品私拍pans大尺度在线 | 久久国产精品久久久| 欧美凹凸一区二区三区视频| 一本色道婷婷久久欧美| 麻豆av一区二区三区| 国产精品视频成人| 日韩午夜黄色| 男人的天堂亚洲| 亚洲欧美在线免费| 欧美日韩你懂的| 亚洲人体偷拍| 美女视频一区免费观看| 亚洲欧美在线一区二区| 欧美日韩八区| 亚洲精品综合| 亚洲国产日韩一区二区| 久久另类ts人妖一区二区| 国产日韩一区二区三区| 亚洲欧美综合| 夜夜爽www精品| 欧美精品激情在线| 亚洲精品在线免费观看视频| 久久激情视频久久| 宅男精品视频| 欧美精品一区二区三| 激情综合在线| 久久激情视频| 午夜精品久久久久久久99热浪潮| 欧美三级视频在线播放| 这里只有精品丝袜| 在线亚洲免费| 国产精品亚洲综合色区韩国| 亚洲一区亚洲| 亚洲一区综合| 国产亚洲精品bt天堂精选| 久久国产精品久久精品国产| 午夜精品福利在线| 韩日视频一区| 欧美二区视频| 欧美精品18videos性欧美| 9久re热视频在线精品| 亚洲伦理在线观看| 国产精品一国产精品k频道56| 先锋影音一区二区三区| 亚洲主播在线播放| 经典三级久久| 亚洲福利在线视频| 欧美日韩国产成人在线观看| 亚洲午夜性刺激影院| 亚洲欧美中文在线视频| 精品电影在线观看| 亚洲欧洲日本国产| 国产精品美女久久| 久久人人爽国产| 欧美激情欧美激情在线五月| 亚洲视频欧美视频| 欧美一区二区免费| 亚洲国产欧美一区二区三区同亚洲| 欧美黄色影院| 国产精品久久久久久久久久妞妞| 久久九九国产精品| 欧美精品91| 久久精品日韩欧美| 欧美精品导航| 久久野战av| 欧美性事免费在线观看| 久久人体大胆视频| 欧美日韩在线播放三区| 久久大香伊蕉在人线观看热2| 久久影视精品| 欧美一区二区视频在线| 麻豆精品91| 欧美一区二区视频97| 欧美xart系列高清| 久久精品亚洲一区二区| 欧美刺激午夜性久久久久久久| 亚洲免费视频观看| 欧美v国产在线一区二区三区| 亚洲欧美激情精品一区二区| 久久婷婷人人澡人人喊人人爽| 亚洲一区视频| 欧美华人在线视频| 美国成人毛片| 国产精品永久免费观看| 亚洲精品日韩在线观看| 欧美性做爰毛片| 一区精品在线| 亚洲片在线资源| 一区久久精品| 亚洲一区二区三区免费观看| 亚洲精品一区中文| 久久一区二区精品| 久久美女性网| 国产一在线精品一区在线观看| 99精品欧美一区二区三区| 亚洲精品黄网在线观看| 久久九九精品| 久久色在线播放| 国模 一区 二区 三区| 亚洲一区二区高清视频| 一区二区三区欧美| 欧美—级在线免费片| 欧美国产欧美亚洲国产日韩mv天天看完整| 国产欧美日韩亚洲精品| 亚洲综合色视频| 午夜欧美大尺度福利影院在线看| 欧美少妇一区| 亚洲一区日韩在线| 欧美一区二区黄| 国产小视频国产精品| 欧美一区二区三区免费观看视频| 亚洲伊人久久综合| 欧美午夜免费影院| 亚洲一区二区三区四区五区黄| 亚洲欧美日韩在线观看a三区 | 久久精品亚洲精品| 国产欧美日韩亚洲精品| 欧美一级理论性理论a| 久久夜色精品亚洲噜噜国产mv| 一色屋精品视频在线观看网站| 久久色中文字幕| 欧美激情影院| 亚洲一区在线免费| 国产亚洲福利| 免费观看成人www动漫视频| 亚洲国产精品福利| 亚洲一区视频| 国产一区二区在线观看免费| 久久精品欧美| 亚洲精品日韩精品| 欧美在线一级va免费观看| 极品尤物久久久av免费看| 久久亚洲电影| aa级大片欧美三级| 久久久水蜜桃| 一区二区日韩免费看| 国产免费一区二区三区香蕉精| 久久久精品网| 99一区二区| 久久久蜜臀国产一区二区| 亚洲激情亚洲| 国产三区二区一区久久 | 国产精品资源在线观看| 欧美在线黄色| 亚洲国产精品一区二区www| 亚洲尤物在线视频观看| 精品av久久久久电影| 欧美网站在线观看| 老司机午夜精品视频| 亚洲一区二区三区在线看| 欧美大尺度在线观看| 欧美一区二区三区视频| 韩日欧美一区二区三区| 亚洲性av在线| 国产精品国产三级国产专播品爱网| 欧美综合激情网| 亚洲日本激情| 久久野战av| 欧美怡红院视频| 99在线精品观看| 亚洲福利电影| 国产女人水真多18毛片18精品视频| 麻豆精品精华液| 欧美在线观看视频在线| 夜夜躁日日躁狠狠久久88av| 欧美jizz19性欧美| 久久免费视频观看| 欧美亚洲日本国产| 亚洲综合欧美日韩| 一区二区三区精品| 99精品国产在热久久下载| 亚洲国产高清视频| 精品动漫一区二区|