What do you want to save?
Add Code snippet
New code examples
-
C 2021-09-15 09:01:04
c get time in milliseconds
#include <sys/time.h> long long current_timestamp() { struct timeval te; gettimeofday(&te, NULL); // get current time long long milliseconds = te.tv_sec*1000LL + te.tv_usec/1000; // calculate milliseconds // printf("millis... Add solution -
C 2021-09-15 00:13:02
total of two times
#include <stdio.h> int main(void) { int s1,s2,s3,m1,m2,m3,h1,h2,h3,d1,d2,d3; printf("hello user ,welcome to the system :\n"); printf("data time 1 :\n"); printf("hours :"); scanf("%d",&h1); printf("... Add solution -
TypeScript 2021-09-14 15:36:04
Sum of digits of a number using recursion function c
/* * C Program to find Sum of Digits of a Number using Recursion */ #include <stdio.h> int sum (int a); int main() { int num, result; printf("Enter the number: "); scanf("%d", &num); r... Add solution -
C++ 2021-09-14 04:31:02
private and public in namespace cpp
#include <cstdio> #include "thing.hpp" int main(int argc, char **argv) { printf("%d\n", thing::getX()); // OK printf("%d\n", thing::getSum()); // OK printf("%d\n", thing::sum(1, 2)); // err... Add solution
Best helpers
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5