code
所属分类:书籍源码
开发工具:C/C++
文件大小:27KB
下载次数:51
上传日期:2008-11-19 17:30:35
上 传 者:
cuiyuzheng
说明: 编程珠玑第二版源码 很好的源码
编程珠玑第二版源码 很好的源码
(Abas programming the second edition of a very good source-source programming Abas second edition of a very good source source)
文件列表:
源代码\源代码\Appendix 3\spacemod.cpp (2532, 2007-12-06)
源代码\源代码\Appendix 3\timemod.c (2627, 2007-12-06)
源代码\源代码\Column 1\bitsort.c (808, 2007-12-06)
源代码\源代码\Column 1\bitsortgen.c (623, 2007-12-06)
源代码\源代码\Column 1\qsortints.c (474, 2007-12-06)
源代码\源代码\Column 1\sortints.cpp (384, 2007-12-06)
源代码\源代码\Column 11\sort.cpp (6881, 2007-12-06)
源代码\源代码\Column 11\SortAnim.java (6435, 2007-12-06)
源代码\源代码\Column 12\sortedrand.cpp (1368, 2007-12-06)
源代码\源代码\Column 13\sets.cpp (8367, 2007-12-06)
源代码\源代码\Column 14\priqueue.cpp (1432, 2007-12-06)
源代码\源代码\Column 15\longdup.c (832, 2007-12-06)
源代码\源代码\Column 15\markov.c (1339, 2007-12-06)
源代码\源代码\Column 15\markovhash.c (1975, 2007-12-06)
源代码\源代码\Column 15\markovlet.c (847, 2007-12-06)
源代码\源代码\Column 15\wordfreq.c (1466, 2007-12-06)
源代码\源代码\Column 15\wordfreq.cpp (448, 2007-12-06)
源代码\源代码\Column 15\wordlist.cpp (422, 2007-12-06)
源代码\源代码\Column 2\rotate.c (4260, 2007-12-06)
源代码\源代码\Column 2\sign.c (587, 2007-12-06)
源代码\源代码\Column 2\squash.c (656, 2007-12-06)
源代码\源代码\Column 5\search.c (5403, 2007-12-06)
源代码\源代码\Column 7\timemod0.c (662, 2007-12-06)
源代码\源代码\Column 8\maxsum.c (3905, 2007-12-06)
源代码\源代码\Column 9\genbins.c (1883, 2007-12-06)
源代码\源代码\Column 9\macfun.c (1431, 2007-12-06)
源代码\源代码\Appendix 3 (0, 2008-08-29)
源代码\源代码\Column 1 (0, 2008-08-29)
源代码\源代码\Column 11 (0, 2008-08-29)
源代码\源代码\Column 12 (0, 2008-08-29)
源代码\源代码\Column 13 (0, 2008-08-29)
源代码\源代码\Column 14 (0, 2008-08-29)
源代码\源代码\Column 15 (0, 2008-08-29)
源代码\源代码\Column 2 (0, 2008-08-29)
源代码\源代码\Column 5 (0, 2008-08-29)
源代码\源代码\Column 7 (0, 2008-08-29)
源代码\源代码\Column 8 (0, 2008-08-29)
源代码\源代码\Column 9 (0, 2008-08-29)
源代码\源代码 (0, 2008-08-29)
... ...
Code from Programming Pearls
Column 1: Programs for sorting integers
bitsort.c -- Sort with bit vectors.
sortints.cpp -- Sort using C++ STL sets.
qsortints.c -- Sort with C library qsort.
bitsortgen.c -- Generate random integers for sorting.
Column 2: Test and time algorithms
rotate.c -- Three ways to rotate the elements of a vector.
The next two program are used in a pipeline to compute all anagrams in a dictionary
sign.c -- Sign each word by its letters in sorted order.
squash.c -- Put each anagram class on a single line.
Column 5: Scaffolding for testing and timing search functions
search.c -- Linear and binary search.
Column 7: Tiny experiment on C run times
timemod0.c -- Edit main to time one operation.
Column 8: Compute the maximum-sum subsequence in an array
maxsum.c -- Time four algs: n3, n2, n log n, n.
Column 9: Code tuning programs
genbins.c -- Profile this, then try a special-purpose allocator.
macfun.c -- Time the cost of macros and functions.
The column also uses rotate.c (Column 2), search.c (Column 5) and maxsum.c (Column 8).
Column 11: Test and time sorting algorithms
sort.cpp -- Mostly C, but also C++ sort function.
SortAnim.java -- Animate those sort functions in Java.
Column 12: Generate a sorted list of random integers
sortedrand.cpp -- Several algorithms for the task.
Column 13: Set representations for the problem in Column 12
sets.cpp -- Several data structures for sets.
genbins.c (Column 9) implements the bin data structure in C.
Column 14: Heaps
priqueue.cpp -- Implement and test priority queues.
The column also uses sort.c (Column 11) for heapsort.
Column 15: Strings
wordlist.cpp -- List words in the file, using STL set.
wordfreq.cpp -- List words in the file, with counts, using STL map.
wordfreq.c -- Same as above, with hash table in C.
longdup.c -- Find long repeated strings in input.
markov.c -- Generate random text from input.
markovhash.c -- Like markov.c, but with hashing.
markovlet.c -- Letter-level markov text, simple algorithm.
Appendix 3: Cost Models
spacemod.cpp -- Space used by various records.
timemod.c -- Table of times used by various C constructs.
You may use this code for any purpose, as long as you leave the copyright notice and book citation attached.
Copyright 1999 Lucent Technologies. All rights reserved. Sat 31 Jul 1999
近期下载者:
相关文件:
收藏者: