Files
cpp-thirdparty/winx64/bin/swig-3.0.12/Examples/guile/simple/example.c
Bassem Girgis 81b4b9e273 Initial commit
2018-12-20 17:34:07 -06:00

22 lines
302 B
C

/* Simple example from documentation */
/* File : example.c */
#include <time.h>
double My_variable = 3.0;
int fact(int n) {
if (n <= 1) return 1;
else return n*fact(n-1);
}
int mod(int n, int m) {
return (n % m);
}
char *get_time() {
long ltime;
time(&ltime);
return ctime(&ltime);
}