What do you want to save?
Add Code snippet
New code examples
-
CSS 2021-11-20 03:20:25
sieve of eratosthenes
// C++ program to print all primes smaller than or equal to // n using Sieve of Eratosthenes #include <bits/stdc++.h> using namespace std; void SieveOfEratosthenes(int n) { // Create a boolean array "prime[0..n]" and initialize /... Add solution -
C++ 2021-11-18 06:54:16
probability code c++
// this the c++ code for generating random numbers //pdf(x) = 1 if x>360 // = 0 if x<0 // = x/360 otherwise #include <iostream> #include <math.h> #include <stdlib.h> using namespace std; //This is a sample program t... Add solution -
C++ 2021-11-14 23:36:14
how to calculate inverse trigonometric values in c++
* C++ Program to Obtain Inverse of a Trigonometric Ratio */ #include <iostream> #include <cmath> #include <iomanip> int main() { double value, result; int choice; std::cout << "Enter a choice " <<... Add solution -
C++ 2021-11-13 01:16:11
heap sort heapify and max heap in binary tree
Implementation of heap sort in C: #include <stdio.h> int main() { int heap[10], array_size, i, j, c, root, temporary; printf("\n Enter size of array to be sorted :"); scanf("%d", &array_size); printf("\n Ent... Add solution -
Other 2021-11-12 23:17:23
gcc to windows
#include <iostream> #include <vector> #include <string> using namespace std; int main() { vector<string> msg {"Hello", "C++", "World", "from", "VS Code", "and the C++ ext... Add solution