-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnicalc.c
More file actions
28 lines (23 loc) · 902 Bytes
/
nicalc.c
File metadata and controls
28 lines (23 loc) · 902 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#include <stdio.h>
#include "nicalc.h"
#include "lex.yy.h"
#include "bison.tab.h"
#include "system.h"
// Función que invoca ao intérprete matemático
void nicalc(char *arg) {
printf("\n---------------------------------------------------------------------------------\n"
"\t\t\t\t NICALC v1.0\n\n"
"Nicalc é un intérprete matemático coa opción de cargar ficheiros con operacións\n"
"e importar librerías de forma dinámica, podendo empregar desta maneira as funcións\n"
"da mesma.\n\n"
"Para máis información sobre o programa e os seus comandos, escribe 'axuda()'.\n"
"---------------------------------------------------------------------------------\n\n\n");
if (arg != NULL) {
if (strcmp(arg, "-h") == 0) {
axuda();
} else {
cargar(arg);
}
}
yyparse();
}