C Programming Code Examples
C > Beginners Lab Assignments Code Examples
Finding LCM and GCD
C++ Program to Perform Greedy Coloring -
Give all its neighbouring colours a vertex, but before that keep a check on used colours and unused colours. 'Only assign', unused colours to the upcoming vertex. The problem takes a
Displays Nodes of a Linked List in Reverse -
C Program uses recursive function & reverses the nodes in a linked list and displays the list. Linked list is an ordered set of data elements, each containing a link to its successor. Code
C Language Reference Enum Value by Int -
C program example to learn reference enum value by int. Press a key to select animal: 1: cat, 2: dog, 3: lion, 4: tiger. Generate a new random number. Read and discard character.
C Programming Code & Logical Operators -
C an expression containing Logical Operator returns either 0 or 1 depending upon whether expression results true or false. C Program to demonstrate working of logical operators...
C Find Sum of N Numbers using Recursion -
C Program using recursion displays the first N 'natural number' on the terminal. User enters the Nth number as the input, C program then displays integral number starting from 1 up to
C Decimal to Binary, Octal HEX Converting -
C programming converting example. Decimal number to Binary number, Octal number and HEX number converter. Enter any number to be converted. The Number has to be in the...
C Program code Find 2 Elements in Array -
Code find 2 Elements in the Array such that Difference between them is Largest. This C Program checks 2 elements in the array such that difference between them is largest and
Code print all unique elements in an array -
C Program to read elements in an array and print all unique element present in array. C program to find unique/distinct elements in an array. Logic to print all unique elements...