Vai al contenuto principale della pagina

Target C# : simple hands-on programming with visual studio 2022 / / Gerard Byrne



(Visualizza in formato marc)    (Visualizza in BIBFRAME)

Autore: Byrne Gerard Visualizza persona
Titolo: Target C# : simple hands-on programming with visual studio 2022 / / Gerard Byrne Visualizza cluster
Pubblicazione: [Place of publication not identified] : , : Apress, , [2022]
©2022
Descrizione fisica: 1 online resource (1084 pages)
Disciplina: 006.7882
Soggetto topico: C# (Computer program language)
Internet programming
Note generali: Includes index.
Nota di contenuto: Intro -- Table of Contents -- About the Author -- Acknowledgments -- Introduction -- Chapter 1: .NET -- .NET: What Is It? -- .NET Core: What Is It? -- C# Language Versioning -- .NET and C# Compilation Process -- Compile Time and Runtime -- Framework and Library -- Library -- Framework -- Managed and Unmanaged Code -- Chapter Summary -- Chapter 2: Software Installation -- About the .NET Framework -- Installing the .NET Framework -- Verify the .NET Framework Installation -- Installing Visual Studio -- Verify the Visual Studio Installation -- Chapter Summary -- Chapter 3: Introduction -- Computer Program -- Programming Languages -- A Computer Program: A Recipe -- Type in C# -- The Basic Operations of a Computer -- C# Program Application Formats -- Format 1: Console Application -- Format 2: .NET MAUI -- Format 3: ASP.NET Web Applications -- The Structure of a C# Program -- Namespaces -- Classes -- Naming a Class: Class Identifiers -- Chapter Summary -- Chapter 4: Input and Output -- Write to and Read from the Console -- Change Console Display Settings -- Chapter Summary -- Chapter 5: Commenting Code -- C# Single-Line Comments -- New .NET 6 Templates -- C# Multiple-Line Comments -- Chapter Summary -- Chapter 6: Data Types -- Data Types, Variables, and Conversion -- Data Types -- Conversion from One Data Type to Another -- Converting -- Something a Little Different with Our Variables -- C# 8 Nullable Reference Types -- Chapter Summary -- Chapter 7: Casting and Parsing -- Data Types, Casting, and Parsing -- Chapter Summary -- Chapter 8: Arithmetic -- Arithmetic Operations -- Common Arithmetic Operators -- Integer Division -- Solution Explorer and Project Analysis -- Other Operators -- Plus Equals ( +=) -- Minus Equals ( -=) -- Multiply Equals ( *=) -- Divide Equals ( /=) -- Square Root -- Chapter Summary -- Chapter 9: Selection -- Arithmetic Operations.
Selection -- Comparison Operators -- The if Construct -- The if-else Construct -- The if else if Construct -- The switch Construct -- The switch Construct Using when -- switch with Strings -- switch with Strings -- Additional Example -- Logical Operators -- Using the AND Operator -- Using the OR Operator -- Using the NOT Operator -- Conditional Operator (Ternary Operator) -- Nested Ternary Conditional Operator -- Chapter Summary -- Chapter 10: Iteration -- Iteration and Loops -- Introduction to Iteration -- For Loop -- Break Statement -- Continue Statement -- While Loop -- Break Statement -- Continue Statement -- Do (While) Loop -- Break Statement -- Continue Statement -- Chapter Summary -- Chapter 11: Arrays -- Arrays: A Data Structure -- Single-Dimensional Arrays -- Choice 1: Declaring and Creating an Array in Two Stages -- Choice 2: Declaring and Creating an Array in One Stage -- Referencing the Array Elements -- foreach Loop -- IndexOutOfBounds Exception -- Ranges and Indices: C# 8 and Above -- Range -- Chapter Summary -- Chapter 12: Methods -- Methods: Modularization -- Methods: Concepts of Methods and Functions -- Some Points Regarding Methods -- Three Types of Methods -- Void Methods -- Value Methods -- Parameter Methods -- Method Overloading -- C# 7 Local Function -- C# 8 Static Local Function -- C# 10 Null Parameter Checking -- C# 10 Null Parameter Checking Approach -- Chapter Summary -- Chapter 13: Classes -- Classes and Objects in OOP -- A Class Is a Data Structure -- Type 1: Fields -- Type 2: Constants -- Type 3: Methods -- Type 4: Properties -- Type 5: Constructor -- Constructor Overloading -- Constructor -- Another Constructor -- Additional Example for Classes and Objects -- CircleFormulae Class -- RectangleFormulae Class -- Chapter Summary -- Chapter 14: Interfaces -- Interfaces and Abstract Classes.
The Interface or Abstract Class as a Manager -- Instantiate the Abstract Class? -- Static Members of the Abstract Class -- Concept of an Interface -- Implementing Multiple Interfaces -- Concept of Default Method in an Interface -- Concept of Static Methods and Fields in an Interface -- Chapter Summary -- Chapter 15: String Handling -- String Handling and Manipulation -- String Literals -- Substring -- Length -- StartsWith() -- Split() -- CompareTo() -- ToUpper() and ToLower() -- Concat() -- Trim() -- Replace() -- Contains() -- IndexOf() -- Insert() -- String.Format() -- Formatting the Items in the String -- String Interpolation -- String Interpolation: Spacing -- @ Verbatim -- What About @ or @? -- Const String Interpolation -- Chapter Summary -- Chapter 16: File Handling -- File Handling -- An Overview of File Handling -- File Class -- Writing to a File -- WriteAllText() -- WriteAllLines() -- WriteAllBytes() -- Reading from a File -- ReadAllText() -- ReadAllLines() -- ReadAllBytes() -- Copy a File -- Copy() -- Delete a File -- Delete() -- StreamReader Class -- Stream -- Synchronous and Asynchronous -- StreamReader Class Methods -- StreamWriter Class -- Reading from a Stream -- Writing to a Stream -- Async Methods and Asynchronous Programming -- WriteLineAsync -- FileStream -- FileModes -- Chapter Summary -- Chapter 17: Exception Handling -- Exceptions -- What Is an Exception? -- try -- catch -- finally -- throw -- Multiple Exceptions -- FileNotFoundException -- finally -- StackTrace -- throw -- rethrow -- Chapter Summary -- Chapter 18: Serialization -- Serialization and Deserialization -- Deserialization -- Attribute [NonSerialized] -- Serializing the Object -- Deserializing the Serialized File to a Class -- Access Modifier [NonSerialized] -- Serialization Using XML -- Serialization Using JSON -- Chapter Summary -- Chapter 19: Structs.
Concept of a Struct as a Structure Type -- Difference Between Struct and Class -- Struct with a Default Constructor Only -- Struct with a User Constructor -- Struct Instantiation Without the New Keyword -- Struct Instantiation with the New Keyword -- Creating a Constructor -- Creating Member Properties (Get and Set Accessors) -- Encapsulation -- Readonly Struct -- Creating a Readonly Struct -- C# 8 readonly Members -- C# 8 Nullable Reference Types -- Chapter Summary -- Chapter 20: Enumerations -- Concept of Enumerations -- Defining an Enumeration -- Enumeration Examples -- Enumerated Values: Use and Scope -- Enumeration Methods -- Using the foreach Iteration -- Enumeration Values: GetValues() -- Assigning Our Own Values to the Enumeration -- Use the GetName() and GetValues() Methods -- Sample Application Using Enumerations -- Chapter Summary -- Chapter 21: Delegates -- Concept of Delegates -- Single Delegate -- Declare the Delegate with Its Return Type and Method Signature -- Instantiate the Delegate and Set Its Target Method -- Invoke the Delegate -- Multicast Delegates -- Instantiate the Delegate Again and Set the New Instances' Target Method -- Chain the Delegates -- Invoke the Multicast Delegate -- More Complex Example -- Chapter Summary -- Chapter 22: Events -- Concept of Events -- Publisher and Subscriber -- Declare an Event -- Raise an Event -- Handle an Event -- Add a Method to an Event Using += -- Refer the Event to a Second Method Using += -- Refer the Event to a Third Method Using += -- Remove a Method from an Event Using -= -- Chapter Summary -- Chapter 23: Generics -- Concept of Generics -- Generic Class, Generic Method, Generic Parameters -- Generic Class, Generic Method, Mixed Parameter Types -- Generic Method Only -- Chapter Summary -- Chapter 24: Common Routines -- Common Programming Routines with C# -- Linear Search.
Create an Application That Will Implement a Linear Search -- Binary Search (Iterative Binary Search) -- Bubble Sort -- Insertion Sort -- Chapter Summary -- Chapter 25: Programming Labs -- C# Practice Exercises -- Chapter 4 Labs: WriteLine() -- Lab 1 -- Lab 2 -- Lab 3 -- Lab 4 -- Lab 1: Possible Solution with output shown in Figure 25-1 -- Lab 2: Possible Solution with output shown in Figure 25-2 -- Lab 3: Possible Solution with output shown in Figure 25-3 -- Lab 4: Possible Solution with output shown in Figure 25-4 -- Chapter 6 Labs: Data Types -- Lab 1 -- Lab 2 -- Lab 3 -- Lab 4 -- Lab 1: Possible Solution with output shown in Figure 25-5 -- Lab 2: Possible Solution with output shown in Figure 25-6 -- Lab 3: Possible Solution with output shown in Figure 25-7 -- Lab 4: Possible Solution with output shown in Figure 25-8 -- Chapter 7 Labs: Data Conversion and Arithmetic -- Lab 1 -- Lab 2 -- Lab 1: Possible Solution with output shown in Figure 25-9 -- Lab 2: Possible Solution with output shown in Figure 25-10 -- Chapter 8 Labs: Arithmetic -- Lab 1 -- Lab 1: Possible Solution with output shown in Figure 25-11 -- Chapter 9 Labs: Selection -- Lab 1 -- Lab 2 -- Lab 3 -- Lab 1: Possible Solution with output shown in Figure 25-12 -- Lab 2: Possible Solution with output shown in Figure 25-13 -- Lab 3: Possible Solution with output shown in Figure 25-14 -- Chapter 10 Labs: Iteration -- Lab 1 -- Lab 2 -- Lab 3 -- Lab 4 -- Lab 1: Possible Solution with output shown in Figure 25-15 -- Lab 2: Possible Solution with output shown in Figure 25-16 -- Lab 3: Possible Solution with output shown in Figure 25-17 -- Lab 4: Possible Solution with output shown in Figure 25-18 -- Chapter 11 Labs: Arrays -- Lab 1 -- Lab 2 -- Lab 3 -- Lab 1: Possible Solution with output shown in Figure 25-19 -- Lab 2: Possible Solution with output shown in Figure 25-20.
Lab 3: Possible Solution with output shown in Figure 25-21.
Sommario/riassunto: So, you want to learn C# and Visual Studio 2022, but are a bit intimidated? Don't be. Programming is within your grasp! Programmers at any level have to fully understand, and more importantly, be able to code the core constructs. It is impossible to use complex programming concepts such as classes before understanding what methods and variables and their data types are. Once there is a foundation built on the basics, then all other topics can fall in line. While it is a forgone conclusion that languages change with the introduction of new features, the core concepts do not. Even large enterprises do not always update to the latest versions of languages and frameworks; their "backbone" applications have been developed to work, regardless. More than ever, enterprises need developers who can master and apply the core programming concepts and then be "up-skilled" with newer language levels and features as they integrate into the company. This book builds from the ground up. You will begin with an introduction to programming, learning the foundational concepts needed to become a C# programmer. You will then put to practice a wide range of programming concepts, including data types, selection, iteration, arrays, methods, classes and objects, serialization, file handling, and string handling. You will learn enough to develop applications that emulate commercial application code. Once you've got the foundational concepts, get ready to dive into common programming routines, including linear search, binary search, bubble sort and insertion sort, and use C# to code them. Code example annotations supplement the learning and are designed to enhance learning while also explaining why the code does what it does. This book: Teaches core programming through well-explained and simple-to-follow instructions Reinforces programming skills through the use of coding examples that extend user learnings Explains theoretical programming concepts; applies them practically with code examples Introduces the latest Microsoft C# Integrated Development Environment (Visual Studio 2022) Enlists clear, precise, and easy-to-understand language to assist readers of all levels and experience Uses a mix of "theory" and practical information that is designed to be friendly and engaging Who This Book Is For Beginners, those refreshing their C# skills, or those moving from another programming language. No skills or previous knowledge is required. Readers will need to download Visual Studio 2022 Community Edition as this is what the book code has been based on, but they could use other Integrated Development Environments.
Titolo autorizzato: Target C  Visualizza cluster
ISBN: 1-4842-8619-7
Formato: Materiale a stampa
Livello bibliografico Monografia
Lingua di pubblicazione: Inglese
Record Nr.: 9910619282703321
Lo trovi qui: Univ. Federico II
Opac: Controlla la disponibilità qui