# C Programming Code Examples

## C > Arrays and Matrices Code Examples

### Find 2 Elements in the Array such that Difference between them is Largest

Check Whether the Number is Palindrome -
If the reversed integer is equal to the integer then, that number is a palindrome if not that number is not a palindrome. In program, use is asked to enter a 'positive number' which is

C++ Tictactoe Game Artificial Intelligence -
Tictactoe playing artificial intelligence. None has defeated this computer ' A.I. ' . The game is very flexible. Either the user or the 'A.I.' can start the game. User is free to select his own

C Programming calculator use Switch Case -
Step by step descriptive logic to create menu driven calculator that performs all basic math operations. Input 2 numbers and a Character from user in the given format. Store them in

C++ Codes Heap's Algorithm Permutation -
The time complexity of this algorithm: 'O(n!)'. This algorithm 'takes the input' of "N" distinct numbers. It fixes an element at the end of the array and permutes the "remaining numbers"

Converts Decimal to Hexadecimal Number -
C program input decimal number and convert to Hexadecimal number system. The Decimal number system is a base 10 number system. Decimal number system uses 10 symbols to...

C Coding Print all the Paths from the Root -
C language program Function to store all the paths from the root node to all leaf nodes in a array. Function which helps the print_path to recursively print all the nodes. Function to...

Writing Data into a Text File C++ program -
A 'while loop' is used and will terminate when user will press esc key. To get the characters a function 'getche()' is used from conio.h which will store in 'char variable' & store into the file

C Program code to Subtract two matrices -
C language read elements in two matrices and find the difference of two matrices. Subtract two matrices in C. Elements of two matrices can only be subtracted if and only...