Đang chuẩn bị nút TẢI XUỐNG, xin hãy chờ
Tải xuống
t is very difficult to determine what are the most popular of modern programming languages. Some languages are very popular for particular kinds of applications (e.g., COBOL is still strong in the corporate data center[citation needed], often on large mainframes, FORTRAN in engineering applications, scripting languages in Web development, and C in embedded applications), while some languages are regularly used to write many different kinds of applications. Also many applications use a mix of several languages in their construction and use. New languages are generally designed around the syntax of a previous language with new functionality added (for example C++. | C Programming Rob Miles Edition 2.1 January 2011 Department of Computer Science EEzE zHEEz zz zzETzEz University of HultxH E Contents Introduction 5 Welcome.5 Reading the notes.5 Getting a copy of the notes.5 1 Computers and Programs 6 1.1 Computers.6 1.2 Programs and Programming.8 1.3 Programming Languages.13 1.4 C . . .14 2 Simple Data Processing 18 2.1 A First C Program . 18 2.2 Manipulating Data . 26 2.3 W riting a Program.37 3 Creating Programs 52 3.1 Methods.52 3.2 Variables and Scope.58 3.3 Arrays.61 3.4 Exceptions and Errors. 65 3.5 The Switch Construction.68 3.6 Using Files.71 4 Creating Solutions 76 4.1 Our Case Study Friendly Bank.76 4.2 Enumerated Types. .76 4.3 Structures.79 4.4 Objects Structures and References . 82 4.5 Designing With Objects.89 4.6 Static Items.94 4.7 The Construction of Objects.98 4.8 From Object to Component.104 4.9 Inheritance.109 4.10 Obj ect Etiquette.119 4.11 The power of strings and chars.124 4.12 Properties.126 4.13 Building a Bank. 129 5 Advanced Programming 134 5.1 Generics and Collections.134 5.2 Storing Business Objects.138 5.3 Business Objects and Editing.148 5.4 A Graphical User Interface.153 5.5 Using Delegates.162 5.6 Threads and Threading.163 i 5.7 Structured Error Handling.171 5.8 Program Organisation.174 5.9 Debugging.180 5.10 The End 7.183 6 Glossary of Terms 184 Abstract. 184 Accessor. 184 Base . 184 Call . 184 Class . 184 Code Reuse . 185 Cohesion . 185 Collection. 185 Compiler . 185 Component. 185 Constructor . 185 Coupling.186 Creative Laziness.186 Delegate.186 Dependency.186 Event.186 Exception.186 Functional Design Specification.187 Globally Unique Identifier GUID .187 Hierarchy.187 Immutable.187 Inheritance.188 Interface.188 Library.188 Machine code.188 Member.188 Metadata.188 Method.188 Mutator.189 Namespace.189 Overload.189 Override.189 Portable.189 Private.189 Property.190 Protected.190 Public.190 Reference.190 Signature.190 Source file.190 Static.190 Stream.191 Structure.191 Subscript.191 Syntax .