What do you want to save?
Add Code snippet
New code examples
-
Other 2022-02-09 23:50:18
how to swap using bitwise operator
#include<stdio.h> void main() { int a,b; printf("Enter the value of a and b: "); scanf("%d %d", &a, &b); a = a^b; b = b^a; a = a^b; printf("Value of a is: %d\n", a); printf("... Add solution -
C++ 2022-02-05 10:40:25
Write a program that asks a user for their birth year encoded as two digits (like "62") and for the current year, also encoded as two digits (like "99"). The program is to correctly write out the users age in years
#include<stdio.h> int main(){ signed int current, birth, a; printf("Enter Year of Birth\n"); scanf("%d",&birth); printf("Enter Current year\n"); scanf("%d",¤t); if(current<birth) ... Add solution -
C 2022-02-02 23:50:43
a program to find the numbers of positive, negative, odd and even numbers in a set of numbers in C
#include <stdio.h> void main () { int a[100]; int num,i; printf("How many numbers do you want to enter? : "); scanf("%d",&num); fflush(stdin); for (i=0;i<num;i++) { printf("Enter %d... Add solution -
Other 2022-02-02 19:20:46
c language quadratic equation
#include <stdio.h> #include <math.h> int main() { int a, b, c, d; double root1, root2; printf("Enter a, b and c where a*x*x + b*x + c = 0\n"); scanf("%d%d%d", &a, &b, &c); d = b*b - 4*a*c; if (d &... Add solution -
Other 2022-02-02 19:11:10
cholesky decomposition c program
#include <stdio.h>#include <stdlib.h>#include <math.h> double *cholesky(double *A, int n) { double *L = (double*)calloc(n * n, sizeof(double)); if (L == NULL) exit(EXIT_FAILURE); for (int i = 0; i < n; i++) ... Add solution