What do you want to save?
Add Code snippet
New code examples
-
C 2021-08-29 17:56:01
increase size of array in c
#include <stdio.h>#include <stdlib.h>int main(){//a pointer to dynamically allocated memory from the heap is returned. int *a = (int *) malloc(20 * sizeof(int));for(int i = 0; i < 20; i++)a[i] = i + 1;printf("\nThe contents of the arra... Add solution -
C++ 2021-08-27 19:49:01
bst traversal code in data structure with c++
#include<iostream> using namespace std; struct node { int data; struct node *left; struct node *right; }; struct node *createNode(int val) { struct node *temp = (struct node *)malloc(sizeof(struct ... Add solution -
TypeScript 2021-08-27 10:59:01
read/write linked lists to file
#include <stdio.h> #include <stdlib.h> typedef struct Node { char name[50]; int age; struct Node *next; }Node; // user-defined functions void printPetRecord(Node *head); void writeToFile(FILE *fptr, Node *head); // main() int ma... Add solution