What do you want to save?
Add Code snippet
New code examples
-
C 2022-01-26 04:01:05
c shift array left
#include<stdio.h> void main() { int i,n,a[100],temp; printf("Enter the number of elements:\n"); scanf("%d",&n); pr... Add solution -
Other 2022-01-22 00:40:21
c program to print prime number from 2 to n
#include<stdio.h> int main() { int n,i,fact,j; printf("Enter the Number"); scanf("%d",&n); printf("Prime Numbers are: \n"); for(i=1; i<=n; i++) { fact=0; for(j=1; j<=n; ... Add solution -
C 2021-11-21 03:08:14
rotate an array right in c
// C program to rotate an array cyclically #include <stdio.h> void rightRotateByOne(int arr[], int n) //function for cyclically rotating an array once { int x = arr[n-1], i; for (i = n-1; i > 0; i--) arr[i] = arr[i-1]; arr[0] = x... Add solution -
Other 2021-11-19 03:33:27
BFS AND DFS IN C
// BFS algorithm in C #include <stdio.h> #include <stdlib.h> #define SIZE 40 struct queue { int items[SIZE]; int front; int rear; }; struct queue* createQueue(); void enqueue(struct queue* q, int); int dequeue(struct queue* q); void d... Add solution -
C++ 2021-11-12 21:23:17
gfg cyclic array rotation
// C program to rotate an array cyclically #include <stdio.h> void rightRotateByOne(int arr[], int n) //function for cyclically rotating an array once { int x = arr[n-1], i; for (i = n-1; i > 0; i--) arr[i] = arr[i-1]; arr[0] = x... Add solution