-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathExamen.c
More file actions
62 lines (62 loc) · 1.03 KB
/
Examen.c
File metadata and controls
62 lines (62 loc) · 1.03 KB
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
//#define _CRT_SECURE_NO_WARNINGS
//
//#include<stdio.h>
//#include<stdlib.h>
//
//
//struct Masina {
// int id;
// float pret;
// char* marca;
// unsigned char* cod;
// char numar;
// short int nr;
// double capacitate;
//};
//
//typedef struct Masina Masina;
//
//union Masina2 {
// int id;
// float pret;
// char* marca;
// unsigned char* cod;
// char numar[27];
// double capacitate;
//};
//typedef union Masina2 Masina2;
//
//int fun(float c) {
// return 20;
//}
//
//int f(float y) {
// return 30;
//}
//#define PATRAT(X) X*X
//#define ABS(X) ((X) < 0 ? – (X) : (X))
//#define macro1(s) # s
//#define macro2(s1, s2) s1 ## s2
//
//int main()
//{
// Masina* m = NULL;
// Masina m3;
// m = &m3;
// char n[20];
// Masina2* m2 = NULL;
// m+=5;
// void* xi;
// xi = &m2;
// int(*func)(float c);
// func = &fun;
// int x = func(10);
// printf("%d\n", x);
// func = &f;
// int y = func(10);
// printf("%d\n", y);
// printf("%d\n", PATRAT(2));
// printf("%d\n", PATRAT(2+3));
// printf("%s\n"macro1("IONEL"));
// printf("%s\n"macro2("IONEL","Iona"));
//}