2 Discussion / Question Topics

Remove Filter
Member Avatar for
Member Avatar for Kirielson

Hello everyone, I'm trying to implement qsort on a struct with the double as a pivot: typedef struct{ char sequence[9]; int occurance; double prob; }tuple; ...... int compare (const void *x, const void *y){ if (x < y) return -1; if (x > y) return 1; else return 0; } …

Member Avatar for deceptikon
0
699
Member Avatar for Hey90

I have created a basic object oriented database of a list of shoes containing the shoe name, number and shoe size. I am trying to sort the list of shoes alphabetially by name and by shoe size. I have the following code: Shoes.h: #include <iostream> #include <fstream> #include <string> #ifndef …

Member Avatar for Hey90
0
4K

The End.