Sort Hash Tables Glibc - qsort
Posted
by Mike
on Stack Overflow
See other posts from Stack Overflow
or by Mike
Published on 2010-03-08T23:53:24Z
Indexed on
2010/03/09
0:06 UTC
Read the original article
Hit count: 342
I'm trying to sort a GLibc hash table by id that looks something like:
key - id
{
"Red", 2,
"BLue", 4,
"Yellow", 5,
"Orange", 8
}
I'm just not sure how to approach this because GLibc does not have a sort method. I was thinking to use qsort or GCompareFunc
Any ideas will be appreciate it!
© Stack Overflow or respective owner