Click here to Skip to main content
15,918,967 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Sorted List Pin
User 988525-Sep-01 12:20
User 988525-Sep-01 12:20 
GeneralRe: Sorted List Pin
User 988525-Sep-01 12:26
User 988525-Sep-01 12:26 
GeneralRe: Sorted List Pin
Christian Graus25-Sep-01 13:48
protectorChristian Graus25-Sep-01 13:48 
GeneralRe: Sorted List Pin
markkuk25-Sep-01 20:39
markkuk25-Sep-01 20:39 
GeneralRe: Sorted List Pin
The_Server25-Sep-01 13:22
The_Server25-Sep-01 13:22 
GeneralRe: Sorted List Pin
Not Active25-Sep-01 11:45
mentorNot Active25-Sep-01 11:45 
GeneralRe: Sorted List Pin
User 988525-Sep-01 12:06
User 988525-Sep-01 12:06 
GeneralRe: Sorted List Pin
The_Server25-Sep-01 13:41
The_Server25-Sep-01 13:41 
binary search works greate with arrays not lists.
because. . .

A list is a conected items in different blocks of memory, while an array is one big block of memory when the items stored one after one after one.

which means that,
to get 14th item from the array, you do this: ar[14]
ar[14] = (*(ar + 14 * sizeof(YourArrObj) ))
while to get 14th item from a list you will to get the 1st item and from there you'll get the 2nd item and then the 3rd and the 4th until you'll get the 14th item

BTW: come to #CodeProject on DalNet (mIRC)
GeneralActive document server & print preview Pin
25-Sep-01 10:53
suss25-Sep-01 10:53 
GeneralDLLs: conceptual questions Pin
Stephen Wilson25-Sep-01 10:19
Stephen Wilson25-Sep-01 10:19 
GeneralRe: DLLs: conceptual questions Pin
Michael P Butler25-Sep-01 10:29
Michael P Butler25-Sep-01 10:29 
GeneralRe: DLLs: conceptual questions Pin
Stephen Wilson25-Sep-01 11:08
Stephen Wilson25-Sep-01 11:08 
GeneralRe: DLLs: conceptual questions Pin
Mike Burston25-Sep-01 12:32
Mike Burston25-Sep-01 12:32 
GeneralThanks! It looks really useful Pin
Stephen Wilson25-Sep-01 13:02
Stephen Wilson25-Sep-01 13:02 
GeneralRe: Thanks! It looks really useful Pin
Mike Burston25-Sep-01 14:31
Mike Burston25-Sep-01 14:31 
GeneralCFindAndReplace Dialog Pin
25-Sep-01 8:33
suss25-Sep-01 8:33 
Generalaccessing adressbar of IE Pin
25-Sep-01 7:06
suss25-Sep-01 7:06 
QuestionHow do I access individual bits? Pin
Craig Miller25-Sep-01 6:42
Craig Miller25-Sep-01 6:42 
AnswerRe: How do I access individual bits? Pin
Chris Losinger25-Sep-01 6:58
professionalChris Losinger25-Sep-01 6:58 
GeneralRe: How do I access individual bits? Pin
Craig Miller26-Sep-01 8:16
Craig Miller26-Sep-01 8:16 
AnswerRe: How do I access individual bits? Pin
User 988525-Sep-01 11:10
User 988525-Sep-01 11:10 
GeneralDirectShow (again) Pin
#realJSOP25-Sep-01 6:40
professional#realJSOP25-Sep-01 6:40 
GeneralNeed a link to article Pin
25-Sep-01 6:36
suss25-Sep-01 6:36 
GeneralRe: Need a link to article Pin
Michael Dunn25-Sep-01 16:59
sitebuilderMichael Dunn25-Sep-01 16:59 
GeneralWTL windows and unchanging cursors Pin
The Arabundi25-Sep-01 6:05
The Arabundi25-Sep-01 6:05 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.