# Visual Basic Programming Code Examples

## Visual Basic > Graphics Games Programming Code Examples

### Creating a Freehand Drawing Tool

Calculate the Sum of the Elements of each -
Program code take the MxN matrix as input. Define two functions separately for row sum and column sum. Use for loops to calculate the sum of the elements of each row and...

Function to Return a String representation -
C Convert an integer to a string. Caller must allocate string array. Function returns string to allow. Use of the function in an expression. Generate digit characters in reverse order...

Code Swap first and last digit of a number -
C program to input a number from user and swap first and last digit of the given number. Input number from user, find last digit, find total number of digit - 1, find first digit. How

Check Whether Number is Strong Number -
How to check Strong Numbers using loop in C. What is Strong number? Strong number is a special number whose sum of factorial of digits is equal to the original number. 145 is

Pointer Simple Program Pass by Reference -
C++ Language program sample which passes a "Reference" to a Function and Function has a 'pointer' as argument. Keep the return type void & display result in main body. Apply any

C++ Program Displays Factors of Number -
Find all 'factors' of an integer using for loop & if statement. Takes a positive integer from an user & displays all the factors of that number. In this program, an integer entered by user is

Find Palindrome Number in C++ language -
We already known that if reverse of a number is equal to the same number, it is Palindrome number. Remember it: certain variables and a loop use to get the reverse of a number which

C++ Program Codes Swaps Two Numbers -
The first program uses temporary variable to swap numbers, whereas the second program doesn't use temporary variables. To perform 'swapping' in above example, three variables