Only Doyle's C# PROGRAMMING: FROM PROBLEM ANALYSIS TO PROGRAM DESIGN, 4E brilliantly balances today's most important programming principles and concepts with the latest insights into C#. This perfect introductory book highlights the latest Visual Studio 2012 and C# 4.0 with a unique, principles-based approach to give readers a deep understanding of programming. You'll find just the right amount of detail to create an important foundation in programming. This edition's straightforward approach and understandable vocabulary make it easier for readers to grasp new programming concepts without distraction. The book introduces a variety of fundamental programming concepts, from data types and expressions to arrays and collections, all using the popular C# language. New programming exercises and new numbered examples throughout this edition reflect the latest updates in Visual Studio 2012, while learning objectives, case studies and Coding Standards summaries in each chapter ensure mastery. While the book assumes no prior programming knowledge, coverage extends beyond traditional books to cover new advanced topics, such as portable class libraries used to create applications for Windows Phone and other platforms. Cover ......Page 1 Title Page ......Page 5 Copyright ......Page 6 Brief Contents......Page 7 Table of Contents......Page 9 Preface......Page 23 Ch 1: Introduction to Computing and Programming......Page 41 History of Computers......Page 42 System and Application Software......Page 44 Software Development Process......Page 46 Programming Methodologies......Page 53 Evolution of C# and .NET......Page 59 Why C#?......Page 63 Types of Applications Developed with C#......Page 64 Exploring the First C# Program......Page 67 Elements of a C# Program......Page 68 Compiling, Building, and Running an Application......Page 78 Debugging an Application......Page 85 Creating an Application......Page 87 Coding Standards......Page 92 Quick Review......Page 93 Exercises......Page 96 Programming Exercises......Page 101 Ch 2: Data Types and Expressions......Page 105 Data Representation......Page 106 Memory Locations for Data......Page 110 Types, Classes, and Objects......Page 116 Predefined Data Types......Page 119 Integral Data Types......Page 122 Floating-Point Types......Page 125 Decimal Types......Page 126 Boolean Variables......Page 127 Making Data Constant......Page 128 Assignment Statements......Page 129 Order of Operations......Page 140 Formatting Output......Page 144 Width Specifier......Page 149 Coding Standards......Page 159 Quick Review......Page 160 Exercises......Page 161 Programming Exercises......Page 167 Ch 3: Methods and Behaviors......Page 171 Anatomy of a Method......Page 172 Calling Class Methods......Page 181 Predefined Methods......Page 183 Writing Your Own Class Methods......Page 197 Types of Parameters......Page 204 Named and Optional Parameters......Page 209 Coding Standards......Page 220 Quick Review......Page 221 Exercises......Page 222 Programming Exercises......Page 229 Ch 4: Creating Your Own Classes......Page 231 The Object Concept......Page 232 Constructor......Page 237 Writing Your Own Instance Methods......Page 240 Calling Instance Methods......Page 246 Coding Standards......Page 275 Resources......Page 276 Quick Review......Page 277 Exercises......Page 278 Programming Exercises......Page 284 Ch 5: Making Decisions......Page 287 Boolean Expressions......Page 288 Conditional Expressions......Page 289 if...else Selection Statements......Page 301 Switch Selection Statements......Page 319 Ternary Operator ? :......Page 323 Order of Operations......Page 325 Coding Standards......Page 338 Resources......Page 340 Quick Review......Page 341 Exercises......Page 342 Programming Exercises......Page 350 Ch 6: Repeating Instructions......Page 353 Using the While Statement......Page 354 Using the for Statement Loop......Page 375 Using the Foreach Statement......Page 382 Using the Do...while Structure......Page 383 Nested Loops......Page 386 Recursive Calls......Page 391 Unconditional Transfer of Control......Page 394 Deciding Which Loop to Use......Page 396 Coding Standards......Page 410 Quick Review......Page 412 Exercises......Page 413 Programming Exercises......Page 419 Ch 7: Arrays......Page 423 Array Basics......Page 424 Array Declaration......Page 425 Array Access......Page 430 Array Class......Page 436 Arrays as Method Parameters......Page 441 Arrays in Classes......Page 448 Coding Standards......Page 468 Quick Review......Page 469 Exercises......Page 470 Programming Exercises......Page 477 Ch 8: Advanced Collections......Page 479 Two-Dimensional Arrays......Page 480 Multidimensional Arrays......Page 490 ArrayList Class......Page 495 String Class......Page 499 Other Collection Classes......Page 505 Resources......Page 519 Quick Review......Page 520 Exercises......Page 521 Programming Exercises......Page 528 Ch 9: Introduction to Windows Programming......Page 533 Contrasting Windows and Console Applications......Page 534 Graphical User Interfaces......Page 536 Elements of Good Design......Page 540 Using C# and Visual Studio to Create Windows-Based Applications......Page 542 Windows Forms......Page 545 Controls......Page 557 Resources......Page 607 Quick Review......Page 608 Exercises......Page 609 Programming Exercises......Page 614 Ch 10: Programming Based on Events......Page 617 Delegates......Page 618 Event Handling in C#......Page 623 ListBox Control Objects......Page 625 ComboBox Control Objects......Page 641 MenuStrip Control Objects......Page 645 CheckBox and RadioButton Objects......Page 658 Windows Presentation Foundation (WPF)......Page 673 TabControl Objects......Page 679 Quick Review......Page 720 Exercises......Page 722 Programming Exercises......Page 728 Ch 11: Advanced Object-Oriented Programming Features......Page 731 Object-Oriented Language Features......Page 732 Component-Based Development......Page 733 Inheritance......Page 734 Making Stand-Alone Components......Page 745 Abstract Classes......Page 761 Sealed Classes......Page 764 Partial Classes......Page 765 Interfaces......Page 766 Polymorphism......Page 774 Generics......Page 777 Dynamic......Page 782 Coding Standards......Page 804 Quick Review......Page 805 Exercises......Page 807 Programming Exercises......Page 812 Ch 12: Debugging and Handling Exceptions......Page 815 Errors......Page 816 Exceptions......Page 826 Exception-Handling Techniques......Page 833 Exception Classes......Page 839 Coding Standards......Page 868 Quick Review......Page 869 Exercises......Page 870 Programming Exercises......Page 875 Ch 13: Working with Files......Page 877 System.IO Namespace......Page 878 File and Directory Classes......Page 880 File Streams......Page 888 BinaryReader and BinaryWriter Classes......Page 903 Quick Review......Page 924 Exercises......Page 925 Programming Exercises......Page 930 Ch 14: Working with Databases......Page 933 Database Access......Page 934 ADO.NET......Page 935 Data Source Configuration Tools......Page 961 Language-Integrated Query (LINQ)......Page 1002 Quick Review......Page 1009 Exercises......Page 1011 Programming Exercises......Page 1016 Ch 15: Web-Based Applications......Page 1019 Web-Based Applications......Page 1020 ASP.NET......Page 1026 Web Forms Page......Page 1028 Controls......Page 1044 Web Forms Standard Server Controls......Page 1052 Validation, Custom, and Composite Controls......Page 1061 Web Services......Page 1090 Smart Device Applications (Optional)......Page 1092 Windows 7.x Phone......Page 1093 Windows 8 Phone Apps......Page 1101 Coding Standards......Page 1113 Resources......Page 1114 Quick Review......Page 1115 Exercises......Page 1116 Programming Exercises......Page 1121 Customizing the Development Environment......Page 1123 Code Snippets......Page 1139 Refactoring......Page 1141 Working with Class Diagrams......Page 1146 Appendix C: Character Sets......Page 1151 Appendix D: Operator Precedence......Page 1153 Appendix E: C# Keywords......Page 1155 Glossary......Page 1157 Index......Page 1171 Only this book brilliantly balances today's most important programming principles and concepts with the latest insights into C♯. This perfect introductory book highlights the latest Visual Studio 2012 and C♯ 4.0 with a unique, principles-based approach to give readers a deep understanding of programming. You'll find just the right amount of detail to create an important foundation in programming. This edition's straightforward approach and understandable vocabulary make it easier for readers to grasp new programming concepts without distraction. The book introduces a variety of fundamental programming concepts, from data types and expressions to arrays and collections, all using the popular C♯ language. New programming exercises and new numbered examples throughout this edition reflect the latest updates in Visual Studio 2012, while learning objectives, case studies and Coding Standards summaries in each chapter ensure mastery. While the book assumes no prior programming knowledge, coverage extends beyond traditional books to cover new advanced topics, such as portable class libraries used to create applications for Windows Phone and other platforms C# Programming: From Problem Analysis to Program Design requires no previous introduction to programming and only a methematical background of high school algebra. The book uses C# as the programming language for software developemnt; however, the basic programming concepts presented an be applied to a number of other languages. ...