Visual C++ .NET is smiling to you, please return her smile

The Visual C++ Programming Tutorials: Loops, Decision and Functions







In the real programming there are many branch or conditional situations. During the program execution, program need to make a decision if more than one way of execution encountered. Program need to do a selection...

This module consists of two part: Program Controls and Functions. Nothing new if you already familiar with C or native C++ program controls and functions. In the loops module you will learn two types of program control that is selection and repetition. In selection you can use the if, if-else, if-else-if and switch-case-break constructs. For the repetition part, you can use while, do-while or for loop. The second part is Functions. It is similar as in C or native C++. Using functions, you can divide your program into a smaller pieces of program based on the specific task that need to be completed. This smaller program or a function can be put in separate files and it is reusable. The following are the topics for this Chapter.

  1. The C++ if Statement: Making Decisions with the if Statement and Performing One-Way Tests

  2. The C++ if-else and if-else-if: Performing Two-Way Tests and Performing Multiway Tests

  3. C++ Nested if and switch-case-break: Performing Nested Tests, Making Decisions with the switch Statement and Defining Simple switch Statements

  4. The C++ switch and while: Defining Fall-Through in a switch Statement, Using Fall-Through in a switch Statement, Performing Loops and Using while Loops



  6. The C++ for and do-while: Using for Loops, Using do-while Loops, Performing Unconditional Jumps and Quick Reference

  7. C++ Function 1: Why Use Functions?, Declaring Function Prototypes, Declaring a Simple Function Prototype, Declaring Parameters in a Function Prototype, Declaring the Return Type in a Function Prototype and Declaring Default Values for Function Parameters

  8. C++ Function 2: Defining Function Bodies, Defining a Simple Function Body, Defining a Function Body That Uses Parameters, Defining a Function Body That Returns a Value, Calling Functions and Calling Functions in the Sample Application

  9. C++ Function 3: Stepping Through the Application with the Debugger, Understanding Local and Global Scope, Overloading Functions and Quick Reference




Best viewed using FireFox, Chrome etc. Worst viewed using IE of any version


Webmaster contact: [contact[@]]

Copyright 2019 © Visualcplusdotnet. All rights reserved.

Excellent hosting services provided by MochaHost - The Online Central



| About | Disclaimer | Privacy | Site Index & Project Download | Native C | Contact |



Custom Search