This commit is contained in:
Maryna Kravtsova 2020-11-01 20:50:49 +01:00
parent a395055ead
commit fb622e0d22

View File

@ -36,7 +36,7 @@ int read_pizza(struct pizza* item){
//compare 2 elements
int compare(const void *a, const void *b){
//to the value const void a(b) we will assign the value of the pointer to the structure
struct pizza* pizza_a = (void*) a;
struct pizza* pizza_b = (void*) b;
float r = (pizza_a->prize > pizza_b->prize) - (pizza_a->prize < pizza_b->prize);