Created
August 16, 2011 16:07
-
-
Save ecounysis/1149436 to your computer and use it in GitHub Desktop.
Learning Clojure
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require '[clojure.contrib.repl-utils :as repl]) | |
(clojure.core/use 'clojure.core) | |
(ns books) | |
(defstruct book :author :title :year :rank) | |
(defmacro makebook [& vs] | |
`(struct-map book ~@vs)) | |
(def | |
^{:books/url "http://www.time.com/time/specials/packages/completelist/0,29569,1951793,00.html"} | |
time-mag [ | |
(makebook :title "The Adventures of Augie March" :year 1953 :author "Saul Bellow") | |
(makebook :title "All the King's Men" :year 1946 :author "Robert Penn Warren") | |
(makebook :title "American Pastoral" :year 1997 :author "Philip Roth") | |
(makebook :title "An American Tragedy" :year 1925 :author "Theodore Dreiser") | |
(makebook :title "Animal Farm" :year 1946 :author "George Orwell") | |
(makebook :title "Appointment in Samarra" :year 1934 :author "John O'Hara") | |
(makebook :title "Are You There God? It's Me, Margaret" :year 1970 :author "Judy Blume") | |
(makebook :title "The Assistant" :year 1957 :author "Bernard Malamud") | |
(makebook :title "At Swim-Two-Birds" :year 1938 :author "Flann O'Brien") | |
(makebook :title "Atonement" :year 2002 :author "Ian McEwan") | |
(makebook :title "Beloved" :year 1987 :author "Toni Morrison") | |
(makebook :title "The Berlin Stories" :year 1946 :author "Christopher Isherwood") | |
(makebook :title "The Big Sleep" :year 1939 :author "Raymond Chandler") | |
(makebook :title "The Blind Assassin" :year 2000 :author "Margaret Atwood") | |
(makebook :title "Blood Meridian" :year 1986 :author "Cormac McCarthy") | |
(makebook :title "Brideshead Revisited" :year 1946 :author "Evelyn Waugh") | |
(makebook :title "The Bridge of San Luis Rey" :year 1927 :author "Thornton Wilder") | |
(makebook :title "Call It Sleep" :year 1935 :author "Henry Roth") | |
(makebook :title "Catch-22" :year 1961 :author "Joseph Heller") | |
(makebook :title "The Catcher in the Rye" :year 1951 :author "J.D. Salinger") | |
(makebook :title "A Clockwork Orange" :year 1963 :author "Anthony Burgess") | |
(makebook :title "The Confessions of Nat Turner" :year 1967 :author "William Styron") | |
(makebook :title "The Corrections" :year 2001 :author "Jonathan Franzen") | |
(makebook :title "The Crying of Lot 49" :year 1966 :author "Thomas Pynchon") | |
(makebook :title "A Dance to the Music of Time" :year 1951 :author "Anthony Powell") | |
(makebook :title "The Day of the Locust" :year 1939 :author "Nathanael West") | |
(makebook :title "Death Comes for the Archbishop" :year 1927 :author "Willa Cather") | |
(makebook :title "A Death in the Family" :year 1958 :author "James Agee") | |
(makebook :title "The Death of the Heart" :year 1958 :author "Elizabeth Bowen") | |
(makebook :title "Deliverance" :year 1970 :author "James Dickey") | |
(makebook :title "Dog Soldiers" :year 1974 :author "Robert Stone") | |
(makebook :title "Falconer" :year 1977 :author "John Cheever") | |
(makebook :title "The French Lieutenant's Woman" :year 1969 :author "John Fowles") | |
(makebook :title "The Golden Notebook" :year 1962 :author "Doris Lessing") | |
(makebook :title "Go Tell it on the Mountain" :year 1953 :author "James Baldwin") | |
(makebook :title "Gone With the Wind" :year 1936 :author "Margaret Mitchell") | |
(makebook :title "The Grapes of Wrath" :year 1939 :author "John Steinbeck") | |
(makebook :title "Gravity's Rainbow" :year 1973 :author "Thomas Pynchon") | |
(makebook :title "The Great Gatsby" :year 1925 :author "F. Scott Fitzgerald") | |
(makebook :title "A Handful of Dust" :year 1934 :author "Evelyn Waugh") | |
(makebook :title "The Heart is A Lonely Hunter" :year 1940 :author "Carson McCullers") | |
(makebook :title "The Heart of the Matter" :year 1948 :author "Graham Greene") | |
(makebook :title "Herzog" :year 1964 :author "Saul Bellow") | |
(makebook :title "Housekeeping" :year 1981 :author "Marilynne Robinson") | |
(makebook :title "A House for Mr. Biswas" :year 1962 :author "V.S. Naipaul") | |
(makebook :title "I, Claudius" :year 1934 :author "Robert Graves") | |
(makebook :title "Infinite Jest" :year 1996 :author "David Foster Wallace") | |
(makebook :title "Invisible Man" :year 1952 :author "Ralph Ellison") | |
(makebook :title "Light in August" :year 1932 :author "William Faulkner") | |
(makebook :title "The Lion, The Witch and the Wardrobe" :year 1950 :author "C.S. Lewis") | |
(makebook :title "Lolita" :year 1955 :author "Vladimir Nabokov") | |
(makebook :title "Lord of the Flies" :year 1955 :author "William Golding") | |
(makebook :title "The Lord of the Rings" :year 1954 :author "J.R.R. Tolkien") | |
(makebook :title "Loving" :year 1945 :author "Henry Green") | |
(makebook :title "Lucky Jim" :year 1954 :author "Kingsley Amis") | |
(makebook :title "The Man Who Loved Children" :year 1940 :author "Christina Stead") | |
(makebook :title "Midnight's Children" :year 1981 :author "Salman Rushdie") | |
(makebook :title "Money" :year 1984 :author "Martin Amis") | |
(makebook :title "The Moviegoer" :year 1961 :author "Walker Percy") | |
(makebook :title "Mrs. Dalloway" :year 1925 :author "Virginia Woolf") | |
(makebook :title "Naked Lunch" :year 1959 :author "William Burroughs") | |
(makebook :title "Native Son" :year 1940 :author "Richard Wright") | |
(makebook :title "Neuromancer" :year 1984 :author "William Gibson") | |
(makebook :title "Never Let Me Go" :year 2005 :author "Kazuo Ishiguro") | |
(makebook :title "1984" :year 1948 :author "George Orwell") | |
(makebook :title "On the Road" :year 1957 :author "Jack Kerouac") | |
(makebook :title "One Flew Over the Cuckoo's Nest" :year 1962 :author "Ken Kesey") | |
(makebook :title "The Painted Bird" :year 1965 :author "Jerzy Kosinski") | |
(makebook :title "Pale Fire" :year 1962 :author "Vladimir Nabokov") | |
(makebook :title "A Passage to India" :year 1924 :author "E.M. Forster") | |
(makebook :title "Play It As It Lays" :year 1970 :author "Joan Didion") | |
(makebook :title "Portnoy's Complaint" :year 1969 :author "Philip Roth") | |
(makebook :title "Possession" :year 1990 :author "A.S. Byatt") | |
(makebook :title "The Power and the Glory" :year 1939 :author "Graham Greene") | |
(makebook :title "The Prime of Miss Jean Brodie" :year 1961 :author "Muriel Spark") | |
(makebook :title "Rabbit, Run" :year 1960 :author "John Updike") | |
(makebook :title "Ragtime" :year 1975 :author "E.L. Doctorow") | |
(makebook :title "The Recognitions" :year 1955 :author "William Gaddis") | |
(makebook :title "Red Harvest" :year 1929 :author "Dashiell Hammett") | |
(makebook :title "Revolutionary Road" :year 1961 :author "Richard Yates") | |
(makebook :title "The Sheltering Sky" :year 1949 :author "Paul Bowles") | |
(makebook :title "Slaughterhouse Five" :year 1969 :author "Kurt Vonnegut") | |
(makebook :title "Snow Crash" :year 1992 :author "Neal Stephenson") | |
(makebook :title "The Sot-Weed Factor" :year 1960 :author "John Barth") | |
(makebook :title "The Sound and the Fury" :year 1929 :author "William Faulkner") | |
(makebook :title "The Sportswriter" :year 1986 :author "Richard Ford") | |
(makebook :title "The Spy Who Came in From the Cold" :year 1964 :author "John le Carre") | |
(makebook :title "The Sun Also Rises" :year 1926 :author "Ernest Hemingway") | |
(makebook :title "Their Eyes Were Watching God" :year 1937 :author "Zora Neale Hurston") | |
(makebook :title "Things Fall Apart" :year 1959 :author "Chinua Achebe") | |
(makebook :title "To Kill a Mockingbird" :year 1960 :author "Harper Lee") | |
(makebook :title "To the Lighthouse" :year 1927 :author "Virginia Woolf") | |
(makebook :title "Tropic of Cancer" :year 1934 :author "Henry Miller") | |
(makebook :title "Ubik" :year 1969 :author "Philip K. Dick") | |
(makebook :title "Under the Net" :year 1954 :author "Iris Murdoch") | |
(makebook :title "Under the Volcano" :year 1947 :author "Malcolm Lowry") | |
(makebook :title "Watchmen" :year 1986 :author "Alan Moore & Dave Gibbons") | |
(makebook :title "White Noise" :year 1985 :author "Don DeLillo") | |
(makebook :title "White Teeth" :year 2000 :author "Zadie Smith") | |
(makebook :title "Wide Sargasso Sea" :year 1966 :author "Jean Rhys")]) | |
(def | |
^{:books/url "http://www.modernlibrary.com/top-100/100-best-novels/"} | |
the-board [ | |
(makebook :title "Ulysses " :author "James Joyce" :rank 1) | |
(makebook :title "The Great Gatsby " :author "F. Scott Fitzgerald" :rank 2) | |
(makebook :title "A Portrait Of The Artist As A Young Man " :author "James Joyce" :rank 3) | |
(makebook :title "Lolita " :author "Vladimir Nabokov" :rank 4) | |
(makebook :title "Brave New World " :author "Aldous Huxley" :rank 5) | |
(makebook :title "The Sound And The Fury " :author "William Faulkner" :rank 6) | |
(makebook :title "Catch-22 " :author "Joseph Heller" :rank 7) | |
(makebook :title "Darkness At Noon " :author "Arthur Koestler" :rank 8) | |
(makebook :title "Sons And Lovers " :author "D.H. Lawrence" :rank 9) | |
(makebook :title "The Grapes Of Wrath " :author "John Steinbeck" :rank 10) | |
(makebook :title "Under The Volcano " :author "Malcolm Lowry" :rank 11) | |
(makebook :title "The Way Of All Flesh " :author "Samuel Butler" :rank 12) | |
(makebook :title "1984 " :author "George Orwell" :rank 13) | |
(makebook :title "I, Claudius " :author "Robert Graves" :rank 14) | |
(makebook :title "To The Lighthouse " :author "Virginia Woolf" :rank 15) | |
(makebook :title "An American Tragedy " :author "Theodore Dreiser" :rank 16) | |
(makebook :title "The Heart Is A Lonely Hunter " :author "Carson McCullers" :rank 17) | |
(makebook :title "Slaughterhouse-Five " :author "Kurt Vonnegut" :rank 18) | |
(makebook :title "Invisible Man " :author "Ralph Ellison" :rank 19) | |
(makebook :title "Native Son " :author "Richard Wright" :rank 20) | |
(makebook :title "Henderson The Rain King " :author "Saul Bellow" :rank 21) | |
(makebook :title "Appointment In Samarra " :author "John O'Hara" :rank 22) | |
(makebook :title "U.S.A.(Trilogy) " :author "John Dos Passos" :rank 23) | |
(makebook :title "Winesburg, Ohio " :author "Sherwood Anderson" :rank 24) | |
(makebook :title "A Passage To India " :author "E.M. Forster" :rank 25) | |
(makebook :title "The Wings Of The Dove " :author "Henry James" :rank 26) | |
(makebook :title "The Ambassadors " :author "Henry James" :rank 27) | |
(makebook :title "Tender Is The Night " :author "F. Scott Fitzgerald" :rank 28) | |
(makebook :title "The Studs Lonigan Trilogy " :author "James T. Farrell" :rank 29) | |
(makebook :title "The Good Soldier " :author "Ford Madox Ford" :rank 30) | |
(makebook :title "Animal Farm " :author "George Orwell" :rank 31) | |
(makebook :title "The Golden Bowl " :author "Henry James" :rank 32) | |
(makebook :title "Sister Carrie " :author "Theodore Dreiser" :rank 33) | |
(makebook :title "A Handful Of Dust " :author "Evelyn Waugh" :rank 34) | |
(makebook :title "As I Lay Dying " :author "William Faulkner" :rank 35) | |
(makebook :title "All The King'S Men " :author "Robert Penn Warren" :rank 36) | |
(makebook :title "The Bridge Of San Luis Rey " :author "Thornton Wilder" :rank 37) | |
(makebook :title "Howards End " :author "E.M. Forster" :rank 38) | |
(makebook :title "Go Tell It On The Mountain " :author "James Baldwin" :rank 39) | |
(makebook :title "The Heart Of The Matter " :author "Graham Greene" :rank 40) | |
(makebook :title "Lord Of The Flies " :author "William Golding" :rank 41) | |
(makebook :title "Deliverance " :author "James Dickey" :rank 42) | |
(makebook :title "A Dance To The Music Of Time (Series) " :author "Anthony Powell" :rank 43) | |
(makebook :title "Point Counter Point " :author "Aldous Huxley" :rank 44) | |
(makebook :title "The Sun Also Rises " :author "Ernest Hemingway" :rank 45) | |
(makebook :title "The Secret Agent " :author "Joseph Conrad" :rank 46) | |
(makebook :title "Nostromo " :author "Joseph Conrad" :rank 47) | |
(makebook :title "The Rainbow " :author "D.H. Lawrence" :rank 48) | |
(makebook :title "Women In Love " :author "D.H. Lawrence" :rank 49) | |
(makebook :title "Tropic Of Cancer " :author "Henry Miller" :rank 50) | |
(makebook :title "The Naked And The Dead " :author "Norman Mailer" :rank 51) | |
(makebook :title "Portnoy'S Complaint " :author "Philip Roth" :rank 52) | |
(makebook :title "Pale Fire " :author "Vladimir Nabokov" :rank 53) | |
(makebook :title "Light In August " :author "William Faulkner" :rank 54) | |
(makebook :title "On The Road " :author "Jack Kerouac" :rank 55) | |
(makebook :title "The Maltese Falcon " :author "Dashiell Hammett" :rank 56) | |
(makebook :title "Parade'S End " :author "Ford Madox Ford" :rank 57) | |
(makebook :title "The Age Of Innocence " :author "Edith Wharton" :rank 58) | |
(makebook :title "Zuleika Dobson " :author "Max Beerbohm" :rank 59) | |
(makebook :title "The Moviegoer " :author "Walker Percy" :rank 60) | |
(makebook :title "Death Comes For The Archbishop " :author "Willa Cather" :rank 61) | |
(makebook :title "From Here To Eternity " :author "James Jones" :rank 62) | |
(makebook :title "The Wapshot Chronicles " :author "John Cheever" :rank 63) | |
(makebook :title "The Catcher In The Rye " :author "J.D. Salinger" :rank 64) | |
(makebook :title "A Clockwork Orange " :author "Anthony Burgess" :rank 65) | |
(makebook :title "Of Human Bondage " :author "W. Somerset Maugham" :rank 66) | |
(makebook :title "Heart Of Darkness " :author "Joseph Conrad" :rank 67) | |
(makebook :title "Main Street " :author "Sinclair Lewis" :rank 68) | |
(makebook :title "The House Of Mirth " :author "Edith Wharton" :rank 69) | |
(makebook :title "The Alexandria Quartet " :author "Lawrence Durell" :rank 70) | |
(makebook :title "A High Wind In Jamaica " :author "Richard Hughes" :rank 71) | |
(makebook :title "A House For Mr Biswas " :author "V.S. Naipaul" :rank 72) | |
(makebook :title "The Day Of The Locust " :author "Nathanael West" :rank 73) | |
(makebook :title "A Farewell To Arms " :author "Ernest Hemingway" :rank 74) | |
(makebook :title "Scoop " :author "Evelyn Waugh" :rank 75) | |
(makebook :title "The Prime Of Miss Jean Brodie " :author "Muriel Spark" :rank 76) | |
(makebook :title "Finnegans Wake " :author "James Joyce" :rank 77) | |
(makebook :title "Kim " :author "Rudyard Kipling" :rank 78) | |
(makebook :title "A Room With A View " :author "E.M. Forster" :rank 79) | |
(makebook :title "Brideshead Revisited " :author "Evelyn Waugh" :rank 80) | |
(makebook :title "The Adventures Of Augie March " :author "Saul Bellow" :rank 81) | |
(makebook :title "Angle Of Repose " :author "Wallace Stegner" :rank 82) | |
(makebook :title "A Bend In The River " :author "V.S. Naipaul" :rank 83) | |
(makebook :title "The Death Of The Heart " :author "Elizabeth Bowen" :rank 84) | |
(makebook :title "Lord Jim " :author "Joseph Conrad" :rank 85) | |
(makebook :title "Ragtime " :author "E.L. Doctorow" :rank 86) | |
(makebook :title "The Old Wives' Tale " :author "Arnold Bennett" :rank 87) | |
(makebook :title "The Call Of The Wild " :author "Jack London" :rank 88) | |
(makebook :title "Loving " :author "Henry Green" :rank 89) | |
(makebook :title "Midnight'S Children " :author "Salman Rushdie" :rank 90) | |
(makebook :title "Tobacco Road " :author "Erskine Caldwell" :rank 91) | |
(makebook :title "Ironweed " :author "William Kennedy" :rank 92) | |
(makebook :title "The Magus " :author "John Fowles" :rank 93) | |
(makebook :title "Wide Sargasso Sea " :author "Jean Rhys" :rank 94) | |
(makebook :title "Under The Net " :author "Iris Murdoch" :rank 95) | |
(makebook :title "Sophie'S Choice " :author "William Styron" :rank 96) | |
(makebook :title "The Sheltering Sky " :author "Paul Bowles" :rank 97) | |
(makebook :title "The Postman Always Rings Twice " :author "James M. Cain" :rank 98) | |
(makebook :title "The Ginger Man " :author "J.P. Donleavy" :rank 99) | |
(makebook :title "The Magnificent Ambersons " :author "Booth Tarkington" :rank 100)]) | |
(def | |
^{:books/url "http://www.modernlibrary.com/top-100/100-best-novels/"} | |
readers [ | |
(makebook :title "Atlas Shrugged " :author "Ayn Rand" :rank 1) | |
(makebook :title "The Fountainhead " :author "Ayn Rand" :rank 2) | |
(makebook :title "Battlefield Earth " :author "L. Ron Hubbard" :rank 3) | |
(makebook :title "The Lord Of The Rings " :author "J.R.R. Tolkien" :rank 4) | |
(makebook :title "To Kill A Mockingbird " :author "Harper Lee" :rank 5) | |
(makebook :title "1984 " :author "George Orwell" :rank 6) | |
(makebook :title "Anthem " :author "Ayn Rand" :rank 7) | |
(makebook :title "We The Living " :author "Ayn Rand" :rank 8) | |
(makebook :title "Mission Earth " :author "L. Ron Hubbard" :rank 9) | |
(makebook :title "Fear " :author "L. Ron Hubbard" :rank 10) | |
(makebook :title "Ulysses " :author "James Joyce" :rank 11) | |
(makebook :title "Catch-22 " :author "Joseph Heller" :rank 12) | |
(makebook :title "The Great Gatsby " :author "F. Scott Fitzgerald" :rank 13) | |
(makebook :title "Dune " :author "Frank Herbert" :rank 14) | |
(makebook :title "The Moon Is A Harsh Mistress " :author "Robert Heinlein" :rank 15) | |
(makebook :title "Stranger In A Strange Land " :author "Robert Heinlein" :rank 16) | |
(makebook :title "A Town Like Alice " :author "Nevil Shute" :rank 17) | |
(makebook :title "Brave New World " :author "Aldous Huxley" :rank 18) | |
(makebook :title "The Catcher In The Rye " :author "J.D. Salinger" :rank 19) | |
(makebook :title "Animal Farm " :author "George Orwell" :rank 20) | |
(makebook :title "Gravity'S Rainbow " :author "Thomas Pynchon" :rank 21) | |
(makebook :title "The Grapes Of Wrath " :author "John Steinbeck" :rank 22) | |
(makebook :title "Slaughterhouse Five " :author "Kurt Vonnegut" :rank 23) | |
(makebook :title "Gone With The Wind " :author "Margaret Mitchell" :rank 24) | |
(makebook :title "Lord Of The Flies " :author "William Golding" :rank 25) | |
(makebook :title "Shane " :author "Jack Schaefer" :rank 26) | |
(makebook :title "Trustee From The Toolroom " :author "Nevil Shute" :rank 27) | |
(makebook :title "A Prayer For Owen Meany " :author "John Irving" :rank 28) | |
(makebook :title "The Stand " :author "Stephen King" :rank 29) | |
(makebook :title "The French Lieutenant'S Woman " :author "John Fowles" :rank 30) | |
(makebook :title "Beloved " :author "Toni Morrison" :rank 31) | |
(makebook :title "The Worm Ouroboros " :author "E.R. Eddison" :rank 32) | |
(makebook :title "The Sound And The Fury " :author "William Faulkner" :rank 33) | |
(makebook :title "Lolita " :author "Vladimir Nabokov" :rank 34) | |
(makebook :title "Moonheart " :author "Charles de Lint" :rank 35) | |
(makebook :title "Absalom, Absalom! " :author "William Faulkner" :rank 36) | |
(makebook :title "Of Human Bondage " :author "W. Somerset Maugham" :rank 37) | |
(makebook :title "Wise Blood " :author "Flannery O'Connor" :rank 38) | |
(makebook :title "Under The Volcano " :author "Malcolm Lowry" :rank 39) | |
(makebook :title "Fifth Business " :author "Robertson Davies" :rank 40) | |
(makebook :title "Someplace To Be Flying " :author "Charles de Lint" :rank 41) | |
(makebook :title "On The Road " :author "Jack Kerouac" :rank 42) | |
(makebook :title "Heart Of Darkness " :author "Joseph Conrad" :rank 43) | |
(makebook :title "Yarrow " :author "Charles de Lint" :rank 44) | |
(makebook :title "At The Mountains Of Madness " :author "H.P. Lovecraft" :rank 45) | |
(makebook :title "One Lonely Night " :author "Mickey Spillane" :rank 46) | |
(makebook :title "Memory And Dream " :author "Charles de Lint" :rank 47) | |
(makebook :title "To The Lighthouse " :author "Virginia Woolf" :rank 48) | |
(makebook :title "The Moviegoer " :author "Walker Percy" :rank 49) | |
(makebook :title "Trader " :author "Charles de Lint" :rank 50) | |
(makebook :title "The Hitchhiker'S Guide To The Galaxy " :author "Douglas Adams" :rank 51) | |
(makebook :title "The Heart Is A Lonely Hunter " :author "Carson McCullers" :rank 52) | |
(makebook :title "The Handmaid'S Tale " :author "Margaret Atwood" :rank 53) | |
(makebook :title "Blood Meridian " :author "Cormac McCarthy" :rank 54) | |
(makebook :title "A Clockwork Orange " :author "Anthony Burgess" :rank 55) | |
(makebook :title "On The Beach " :author "Nevil Shute" :rank 56) | |
(makebook :title "A Portrait Of The Artist As A Young Man " :author "James Joyce" :rank 57) | |
(makebook :title "Greenmantle " :author "Charles de Lint" :rank 58) | |
(makebook :title "Ender'S Game " :author "Orson Scott Card" :rank 59) | |
(makebook :title "The Little Country " :author "Charles de Lint" :rank 60) | |
(makebook :title "The Recognitions " :author "William Gaddis" :rank 61) | |
(makebook :title "Starship Troopers " :author "Robert Heinlein" :rank 62) | |
(makebook :title "The Sun Also Rises " :author "Ernest Hemingway" :rank 63) | |
(makebook :title "The World According To Garp " :author "John Irving" :rank 64) | |
(makebook :title "Something Wicked This Way Comes " :author "Ray Bradbury" :rank 65) | |
(makebook :title "The Haunting Of Hill House " :author "Shirley Jackson" :rank 66) | |
(makebook :title "As I Lay Dying " :author "William Faulkner" :rank 67) | |
(makebook :title "Tropic Of Cancer " :author "Henry Miller" :rank 68) | |
(makebook :title "Invisible Man " :author "Ralph Ellison" :rank 69) | |
(makebook :title "The Wood Wife " :author "Terri Windling" :rank 70) | |
(makebook :title "The Magus " :author "John Fowles" :rank 71) | |
(makebook :title "The Door Into Summer " :author "Robert Heinlein" :rank 72) | |
(makebook :title "Zen And The Art Of Motorcycle Maintenance " :author "Robert Pirsig" :rank 73) | |
(makebook :title "I, Claudius " :author "Robert Graves" :rank 74) | |
(makebook :title "The Call Of The Wild " :author "Jack London" :rank 75) | |
(makebook :title "At Swim-Two-Birds " :author "Flann O'Brien" :rank 76) | |
(makebook :title "Farenheit 451 " :author "Ray Bradbury" :rank 77) | |
(makebook :title "Arrowsmith " :author "Sinclair Lewis" :rank 78) | |
(makebook :title "Watership Down " :author "Richard Adams" :rank 79) | |
(makebook :title "Naked Lunch " :author "William S. Burroughs" :rank 80) | |
(makebook :title "The Hunt For Red October " :author "Tom Clancy" :rank 81) | |
(makebook :title "Guilty Pleasures " :author "Laurell K. Hamilton" :rank 82) | |
(makebook :title "The Puppet Masters " :author "Robert Heinlein" :rank 83) | |
(makebook :title "It " :author "Stephen King" :rank 84) | |
(makebook :title "V. " :author "Thomas Pynchon" :rank 85) | |
(makebook :title "Double Star " :author "Robert Heinlein" :rank 86) | |
(makebook :title "Citizen Of The Galaxy " :author "Robert Heinlein" :rank 87) | |
(makebook :title "Brideshead Revisited " :author "Evelyn Waugh" :rank 88) | |
(makebook :title "Light In August " :author "William Faulkner" :rank 89) | |
(makebook :title "One Flew Over The Cuckoo's Nest " :author "Ken Kesey" :rank 90) | |
(makebook :title "A Farewell To Arms " :author "Ernest Hemingway" :rank 91) | |
(makebook :title "The Sheltering Sky " :author "Paul Bowles" :rank 92) | |
(makebook :title "Sometimes A Great Notion " :author "Ken Kesey" :rank 93) | |
(makebook :title "My Antonia " :author "Willa Cather" :rank 94) | |
(makebook :title "Mulengro " :author "Charles de Lint" :rank 95) | |
(makebook :title "Suttree " :author "Cormac McCarthy" :rank 96) | |
(makebook :title "Mythago Wood " :author "Robert Holdstock" :rank 97) | |
(makebook :title "Illusions " :author "Richard Bach" :rank 98) | |
(makebook :title "The Cunning Man " :author "Robertson Davies" :rank 99) | |
(makebook :title "The Satanic Verses " :author "Salman Rushdie" :rank 100)]) | |
(def | |
^{:books/url ""} | |
the-century [ | |
(makebook :title "The Great Gatsby " :author "F. Scott Fitzgerald" :rank 1) | |
(makebook :title "The Catcher in the Rye " :author "J.D. Salinger" :rank 2) | |
(makebook :title "The Grapes of Wrath " :author "John Steinbeck" :rank 3) | |
(makebook :title "To Kill a Mockingbird " :author "Harper Lee" :rank 4) | |
(makebook :title "The Color Purple " :author "Alice Walker" :rank 5) | |
(makebook :title "Ulysses " :author "James Joyce" :rank 6) | |
(makebook :title "Beloved " :author "Toni Morrison" :rank 7) | |
(makebook :title "The Lord of the Flies " :author "William Golding" :rank 8) | |
(makebook :title "1984 " :author "George Orwell" :rank 9) | |
(makebook :title "The Sound and the Fury " :author "William Faulkner" :rank 10) | |
(makebook :title "Lolita " :author "Vladmir Nabokov" :rank 11) | |
(makebook :title "Of Mice and Men " :author "John Steinbeck" :rank 12) | |
(makebook :title "Charlotte's Web " :author "E.B. White" :rank 13) | |
(makebook :title "A Portrait of the Artist as a Young Man " :author "James Joyce" :rank 14) | |
(makebook :title "Catch-22 " :author "Joseph Heller" :rank 15) | |
(makebook :title "Brave New World " :author "Aldous Huxley" :rank 16) | |
(makebook :title "Animal Farm " :author "George Orwell" :rank 17) | |
(makebook :title "The Sun Also Rises " :author "Ernest Hemingway" :rank 18) | |
(makebook :title "As I Lay Dying " :author "William Faulkner" :rank 19) | |
(makebook :title "A Farewell to Arms " :author "Ernest Hemingway" :rank 20) | |
(makebook :title "Heart of Darkness " :author "Joseph Conrad" :rank 21) | |
(makebook :title "Winnie-the-Pooh " :author "A.A. Milne" :rank 22) | |
(makebook :title "Their Eyes Were Watching God " :author "Zora Neale Hurston" :rank 23) | |
(makebook :title "Invisible Man " :author "Ralph Ellison" :rank 24) | |
(makebook :title "Song of Solomon " :author "Toni Morrison" :rank 25) | |
(makebook :title "Gone with the Wind " :author "Margaret Mitchell" :rank 26) | |
(makebook :title "Native Son " :author "Richard Wright" :rank 27) | |
(makebook :title "One Flew Over the Cuckoo's Nest " :author "Ken Kesey" :rank 28) | |
(makebook :title "Slaughterhouse-Five " :author "Kurt Vonnegut" :rank 29) | |
(makebook :title "For Whom the Bell Tolls " :author "Ernest Hemingway" :rank 30) | |
(makebook :title "On the Road " :author "Jack Kerouac" :rank 31) | |
(makebook :title "The Old Man and the Sea " :author "Ernest Hemingway" :rank 32) | |
(makebook :title "The Call of the Wild " :author "Jack London" :rank 33) | |
(makebook :title "To the Lighthouse " :author "Virginia Woolf" :rank 34) | |
(makebook :title "Portrait of a Lady " :author "Henry James" :rank 35) | |
(makebook :title "Go Tell it on the Mountain " :author "James Baldwin" :rank 36) | |
(makebook :title "The World According to Garp " :author "John Irving" :rank 37) | |
(makebook :title "All the King's Men " :author "Robert Penn Warren" :rank 38) | |
(makebook :title "A Room with a View " :author "E.M. Forster" :rank 39) | |
(makebook :title "The Lord of the Rings " :author "J.R.R. Tolkien" :rank 40) | |
(makebook :title "Schindler's List " :author "Thomas Keneally" :rank 41) | |
(makebook :title "The Age of Innocence " :author "Edith Wharton" :rank 42) | |
(makebook :title "The Fountainhead " :author "Ayn Rand" :rank 43) | |
(makebook :title "Finnegans Wake " :author "James Joyce" :rank 44) | |
(makebook :title "The Jungle " :author "Upton Sinclair" :rank 45) | |
(makebook :title "Mrs. Dalloway " :author "Virginia Woolf" :rank 46) | |
(makebook :title "The Wonderful Wizard of Oz " :author "L. Frank Baum" :rank 47) | |
(makebook :title "Lady Chatterley's Lover " :author "D.H. Lawrence" :rank 48) | |
(makebook :title "A Clockwork Orange " :author "Anthony Burgess" :rank 49) | |
(makebook :title "The Awakening " :author "Kate Chopin" :rank 50) | |
(makebook :title "My Antonia " :author "Willa Cather" :rank 51) | |
(makebook :title "Howards End " :author "E.M. Forster" :rank 52) | |
(makebook :title "In Cold Blood " :author "Truman Capote" :rank 53) | |
(makebook :title "Franny and Zooey " :author "J.D. Salinger" :rank 54) | |
(makebook :title "The Satanic Verses " :author "Salman Rushdie" :rank 55) | |
(makebook :title "Jazz " :author "Toni Morrison" :rank 56) | |
(makebook :title "Sophie's Choice " :author "William Styron" :rank 57) | |
(makebook :title "Absalom, Absalom! " :author "William Faulkner" :rank 58) | |
(makebook :title "A Passage to India " :author "E.M. Forster" :rank 59) | |
(makebook :title "Ethan Frome " :author "Edith Wharton" :rank 60) | |
(makebook :title "A Good Man Is Hard to Find " :author "Flannery O'Connor" :rank 61) | |
(makebook :title "Tender Is the Night " :author "F. Scott Fitzgerald" :rank 62) | |
(makebook :title "Orlando " :author "Virginia Woolf" :rank 63) | |
(makebook :title "Sons and Lovers " :author "D.H. Lawrence" :rank 64) | |
(makebook :title "Bonfire of the Vanities " :author "Tom Wolfe" :rank 65) | |
(makebook :title "Cat's Cradle " :author "Kurt Vonnegut" :rank 66) | |
(makebook :title "A Separate Peace " :author "John Knowles" :rank 67) | |
(makebook :title "Light in August " :author "William Faulkner" :rank 68) | |
(makebook :title "The Wings of the Dove " :author "Henry James" :rank 69) | |
(makebook :title "Things Fall Apart " :author "Chinua Achebe" :rank 70) | |
(makebook :title "Rebecca " :author "Daphne du Maurier" :rank 71) | |
(makebook :title "A Hitchhiker's Guide to the Galaxy " :author "Douglas Adams" :rank 72) | |
(makebook :title "Naked Lunch " :author "William S. Burroughs" :rank 73) | |
(makebook :title "Brideshead Revisited " :author "Evelyn Waugh" :rank 74) | |
(makebook :title "Women in Love " :author "D.H. Lawrence" :rank 75) | |
(makebook :title "Look Homeward, Angel " :author "Thomas Wolfe" :rank 76) | |
(makebook :title "In Our Time " :author "Ernest Hemingway" :rank 77) | |
(makebook :title "The Autobiography of Alice B. Tokias " :author "Gertrude Stein" :rank 78) | |
(makebook :title "The Maltese Falcon " :author "Dashiell Hammett" :rank 79) | |
(makebook :title "The Naked and the Dead " :author "Norman Mailer" :rank 80) | |
(makebook :title "Wide Sargasso Sea " :author "Jean Rhys" :rank 81) | |
(makebook :title "White Noise " :author "Don DeLillo" :rank 82) | |
(makebook :title "O Pioneers! " :author "Willa Cather" :rank 83) | |
(makebook :title "Tropic of Cancer " :author "Henry Miller" :rank 84) | |
(makebook :title "The War of the Worlds " :author "H.G. Wells" :rank 85) | |
(makebook :title "Lord Jim " :author "Joseph Conrad" :rank 86) | |
(makebook :title "The Bostonians " :author "Henry James" :rank 87) | |
(makebook :title "An American Tragedy " :author "Theodore Dreiser" :rank 88) | |
(makebook :title "Death Comes for the Archbishop " :author "Willa Cather" :rank 89) | |
(makebook :title "The Wind in the Willows " :author "Kenneth Grahame" :rank 90) | |
(makebook :title "This Side of Paradise " :author "F. Scott Fitzgerald" :rank 91) | |
(makebook :title "Atlas Shrugged " :author "Ayn Rand" :rank 92) | |
(makebook :title "The French Lieutenant's Woman " :author "John Fowles" :rank 93) | |
(makebook :title "Babbitt " :author "Sinclair Lewis" :rank 94) | |
(makebook :title "Kim " :author "Rudyard Kipling" :rank 95) | |
(makebook :title "The Beautiful and the Damned " :author "F. Scott Fitzgerald" :rank 96) | |
(makebook :title "Rabbit, Run " :author "John Updike" :rank 97) | |
(makebook :title "Where Angels Fear to Tread " :author "E.M. Forster" :rank 98) | |
(makebook :title "Main Street " :author "Sinclair Lewis" :rank 99) | |
(makebook :title "Midnight's Children " :author "Salman Rushdie" :rank 100)]) | |
(def | |
^{:books/url "http://www.npr.org/2011/08/09/139248590/top-100-science-fiction-fantasy-books"} | |
npr-scifi [ | |
(makebook :rank 1 :title "The Lord Of The Rings Trilogy" :author "J.R.R. Tolkien") | |
(makebook :rank 2 :title "The Hitchhiker's Guide To The Galaxy" :author "Douglas Adams") | |
(makebook :rank 3 :title "Ender's Game" :author "Orson Scott Card") | |
(makebook :rank 4 :title "The Dune Chronicles" :author "Frank Herbert") | |
(makebook :rank 5 :title "A Song Of Ice And Fire Series" :author "George R. R. Martin") | |
(makebook :rank 6 :title "1984" :author "George Orwell") | |
(makebook :rank 7 :title "Fahrenheit 451" :author "Ray Bradbury") | |
(makebook :rank 8 :title "The Foundation Trilogy" :author "Isaac Asimov") | |
(makebook :rank 9 :title "Brave New World" :author "Aldous Huxley") | |
(makebook :rank 10 :title "American Gods" :author "Neil Gaiman") | |
(makebook :rank 11 :title "The Princess Bride" :author "William Goldman") | |
(makebook :rank 12 :title "The Wheel Of Time Series" :author "Robert Jordan") | |
(makebook :rank 13 :title "Animal Farm" :author "George Orwell") | |
(makebook :rank 14 :title "Neuromancer" :author "William Gibson") | |
(makebook :rank 15 :title "Watchmen" :author "Alan Moore") | |
(makebook :rank 16 :title "I, Robot" :author "Isaac Asimov") | |
(makebook :rank 17 :title "Stranger In A Strange Land" :author "Robert Heinlein") | |
(makebook :rank 18 :title "The Kingkiller Chronicles" :author "Patrick Rothfuss") | |
(makebook :rank 19 :title "Slaughterhouse-Five" :author "Kurt Vonnegut") | |
(makebook :rank 20 :title "Frankenstein" :author "Mary Shelley") | |
(makebook :rank 21 :title "Do Androids Dream Of Electric Sheep?" :author "Philip K. Dick") | |
(makebook :rank 22 :title "The Handmaid's Tale" :author "Margaret Atwood") | |
(makebook :rank 23 :title "The Dark Tower Series" :author "Stephen King") | |
(makebook :rank 24 :title "2001: A Space Odyssey" :author "Arthur C. Clarke") | |
(makebook :rank 25 :title "The Stand" :author "Stephen King") | |
(makebook :rank 26 :title "Snow Crash" :author "Neal Stephenson") | |
(makebook :rank 27 :title "The Martian Chronicles" :author "Ray Bradbury") | |
(makebook :rank 28 :title "Cat's Cradle" :author "Kurt Vonnegut") | |
(makebook :rank 29 :title "The Sandman Series" :author "Neil Gaiman") | |
(makebook :rank 30 :title "A Clockwork Orange" :author "Anthony Burgess") | |
(makebook :rank 31 :title "Starship Troopers" :author "Robert Heinlein") | |
(makebook :rank 32 :title "Watership Down" :author "Richard Adams") | |
(makebook :rank 33 :title "Dragonflight" :author "Anne McCaffrey") | |
(makebook :rank 34 :title "The Moon Is A Harsh Mistress" :author "Robert Heinlein") | |
(makebook :rank 35 :title "A Canticle For Leibowitz" :author "Walter M. Miller") | |
(makebook :rank 36 :title "The Time Machine" :author "H.G. Wells") | |
(makebook :rank 37 :title "20,000 Leagues Under The Sea" :author "Jules Verne") | |
(makebook :rank 38 :title "Flowers For Algernon" :author "Daniel Keys") | |
(makebook :rank 39 :title "The War Of The Worlds" :author "H.G. Wells") | |
(makebook :rank 40 :title "The Chronicles Of Amber" :author "Roger Zelazny") | |
(makebook :rank 41 :title "The Belgariad" :author "David Eddings") | |
(makebook :rank 42 :title "The Mists Of Avalon" :author "Marion Zimmer Bradley") | |
(makebook :rank 43 :title "The Mistborn Series" :author "Brandon Sanderson") | |
(makebook :rank 44 :title "Ringworld" :author "Larry Niven") | |
(makebook :rank 45 :title "The Left Hand Of Darkness" :author "Ursula K. LeGuin") | |
(makebook :rank 46 :title "The Silmarillion" :author "J.R.R. Tolkien") | |
(makebook :rank 47 :title "The Once And Future King" :author "T.H. White") | |
(makebook :rank 48 :title "Neverwhere" :author "Neil Gaiman") | |
(makebook :rank 49 :title "Childhood's End" :author "Arthur C. Clarke") | |
(makebook :rank 50 :title "Contact" :author "Carl Sagan") | |
(makebook :rank 51 :title "The Hyperion Cantos" :author "Dan Simmons") | |
(makebook :rank 52 :title "Stardust" :author "Neil Gaiman") | |
(makebook :rank 53 :title "Cryptonomicon" :author "Neal Stephenson") | |
(makebook :rank 54 :title "World War Z" :author "Max Brooks") | |
(makebook :rank 55 :title "The Last Unicorn" :author "Peter S. Beagle") | |
(makebook :rank 56 :title "The Forever War" :author "Joe Haldeman") | |
(makebook :rank 57 :title "Small Gods" :author "Terry Pratchett") | |
(makebook :rank 58 :title "The Chronicles Of Thomas Covenant, Unbeliever" :author "Stephen R. Donaldson") | |
(makebook :rank 59 :title "The Vorkosigan Saga" :author "Lois McMaster Bujold") | |
(makebook :rank 60 :title "Going Postal" :author "Terry Pratchett") | |
(makebook :rank 61 :title "The Mote In God's Eye" :author "Larry Niven & Jerry Pournelle") | |
(makebook :rank 62 :title "The Sword Of Truth" :author "Terry Goodkind") | |
(makebook :rank 63 :title "The Road" :author "Cormac McCarthy") | |
(makebook :rank 64 :title "Jonathan Strange & Mr Norrell" :author "Susanna Clarke") | |
(makebook :rank 65 :title "I Am Legend" :author "Richard Matheson") | |
(makebook :rank 66 :title "The Riftwar Saga" :author "Raymond E. Feist") | |
(makebook :rank 67 :title "The Shannara Trilogy" :author "Terry Brooks") | |
(makebook :rank 68 :title "The Conan The Barbarian Series" :author "R.E. Howard") | |
(makebook :rank 69 :title "The Farseer Trilogy" :author "Robin Hobb") | |
(makebook :rank 70 :title "The Time Traveler's Wife" :author "Audrey Niffenegger") | |
(makebook :rank 71 :title "The Way Of Kings" :author "Brandon Sanderson") | |
(makebook :rank 72 :title "A Journey To The Center Of The Earth" :author "Jules Verne") | |
(makebook :rank 73 :title "The Legend Of Drizzt Series" :author "R.A. Salvatore") | |
(makebook :rank 74 :title "Old Man's War" :author "John Scalzi") | |
(makebook :rank 75 :title "The Diamond Age" :author "Neal Stephenson") | |
(makebook :rank 76 :title "Rendezvous With Rama" :author "Arthur C. Clarke") | |
(makebook :rank 77 :title "The Kushiel's Legacy Series" :author "Jacqueline Carey") | |
(makebook :rank 78 :title "The Dispossessed" :author "Ursula K. LeGuin") | |
(makebook :rank 79 :title "Something Wicked This Way Comes" :author "Ray Bradbury") | |
(makebook :rank 80 :title "Wicked" :author "Gregory Maguire") | |
(makebook :rank 81 :title "The Malazan Book Of The Fallen Series" :author "Steven Erikson") | |
(makebook :rank 82 :title "The Eyre Affair" :author "Jasper Fforde") | |
(makebook :rank 83 :title "The Culture Series" :author "Iain M. Banks") | |
(makebook :rank 84 :title "The Crystal Cave" :author "Mary Stewart") | |
(makebook :rank 85 :title "Anathem" :author "Neal Stephenson") | |
(makebook :rank 86 :title "The Codex Alera Series" :author "Jim Butcher") | |
(makebook :rank 87 :title "The Book Of The New Sun" :author "Gene Wolfe") | |
(makebook :rank 88 :title "The Thrawn Trilogy" :author "Timothy Zahn") | |
(makebook :rank 89 :title "The Outlander Series" :author "Diana Gabaldan") | |
(makebook :rank 90 :title "The Elric Saga" :author "Michael Moorcock") | |
(makebook :rank 91 :title "The Illustrated Man" :author "Ray Bradbury") | |
(makebook :rank 92 :title "Sunshine" :author "Robin McKinley") | |
(makebook :rank 93 :title "A Fire Upon The Deep" :author "Vernor Vinge") | |
(makebook :rank 94 :title "The Caves Of Steel" :author "Isaac Asimov") | |
(makebook :rank 95 :title "The Mars Trilogy" :author "Kim Stanley Robinson") | |
(makebook :rank 96 :title "Lucifer's Hammer" :author "Larry Niven & Jerry Pournelle") | |
(makebook :rank 97 :title "Doomsday Book" :author "Connie Willis") | |
(makebook :rank 98 :title "Perdido Street Station" :author "China Mieville") | |
(makebook :rank 99 :title "The Xanth Series" :author "Piers Anthony") | |
(makebook :rank 100 :title "The Space Trilogy" :author "C.S. Lewis")]) | |
(def | |
^{:books/url "http://home.comcast.net/~antaylor1/waterstones100.html"} | |
waterstones [ | |
(makebook :rank 1 :author "J.R.R. Tolkien" :title "The Lord of the Rings") | |
(makebook :rank 2 :author "George Orwell" :title "1984") | |
(makebook :rank 3 :author "George Orwell" :title "Animal Farm") | |
(makebook :rank 4 :author "James Joyce" :title "Ulysses") | |
(makebook :rank 5 :author "Joseph Heller" :title "Catch-22") | |
(makebook :rank 6 :author "J.D. Salinger" :title "The Catcher in the Rye") | |
(makebook :rank 7 :author "Harper lee" :title "To Kill a Mocking Bird") | |
(makebook :rank 8 :author "Gabriel Garcia Marquez" :title "One Hundred Years of Solitude") | |
(makebook :rank 9 :author "John Steinbeck" :title "The Grapes of Wrath") | |
(makebook :rank 10 :author "Irvine Welsh" :title "Trainspotting") | |
(makebook :rank 11 :author "Jung Chan" :title "Wild Swans") | |
(makebook :rank 12 :author "F. Scott Fitzgerald" :title "The Great Gatsby") | |
(makebook :rank 13 :author "William Golding " :title "The Lord of the Flies") | |
(makebook :rank 14 :author "Jack Kerouac" :title "On the Road") | |
(makebook :rank 15 :author "Aldous Huxley" :title "Brave New World") | |
(makebook :rank 16 :author "Kenneth Grahame" :title "The Wind in the Willows") | |
(makebook :rank 17 :author "A.A. Milne" :title "Winnie the Pooh") | |
(makebook :rank 18 :author "Alice Walker" :title "The Colour Purple") | |
(makebook :rank 19 :author "J.R.R. Tolkien" :title "The Hobbit") | |
(makebook :rank 20 :author "Albert Camus" :title "The Outsider") | |
(makebook :rank 21 :author "C.S. Lewis" :title "The Lion, the Witch and the Wardrobe") | |
(makebook :rank 22 :author "Franz Kafka" :title "The Trial") | |
(makebook :rank 23 :author "Margaret Mitchell" :title "Gone With the Wind") | |
(makebook :rank 24 :author "Douglas Adams" :title "The Hitchhiker's Guide to the Galaxy") | |
(makebook :rank 25 :author "Salman Rushdie" :title "Midnight's Children") | |
(makebook :rank 26 :author "Anne Frank" :title "The Diary of Anne Frank") | |
(makebook :rank 27 :author "Anthony Burgess" :title "A Clockwork Orange") | |
(makebook :rank 28 :author "D.H. Lawrence" :title "Sons and Lovers") | |
(makebook :rank 29 :author "Virginia Woolf" :title "To the Lighthouse") | |
(makebook :rank 30 :author "Primo Levi" :title "If This Is a Man") | |
(makebook :rank 31 :author "Vladimir Nabokov" :title "Lolita") | |
(makebook :rank 32 :author "Iain Banks" :title "The Wasp Factory") | |
(makebook :rank 33 :author "Marcel Proust" :title "A la Recherche du Temps Perdu (Remembrance of Things Past)") | |
(makebook :rank 34 :author "Roald Dahl" :title "Charlie and the Chocolate Factory") | |
(makebook :rank 35 :author "John Steinbeck" :title "Of Mice and Men") | |
(makebook :rank 36 :author "Toni Morrison" :title "Beloved") | |
(makebook :rank 37 :author "A.S. Byatt" :title "Posession") | |
(makebook :rank 38 :author "Joseph Conrad" :title "The Heart of Darkness") | |
(makebook :rank 39 :author "E.M. Forster" :title "A Passage to India") | |
(makebook :rank 40 :author "Richard Adams" :title "Watership Down") | |
(makebook :rank 41 :author "Jostein Gaarder" :title "Sophie's World") | |
(makebook :rank 42 :author "Umberto Eco" :title "The Name of the Rose") | |
(makebook :rank 43 :author "Gabriel Garcia Marquez" :title "Love in a Time of Cholera") | |
(makebook :rank 44 :author "Daphne du Maurier" :title "Rebecca") | |
(makebook :rank 45 :author "Kazuo Ishiguri" :title "The Remains of the Day") | |
(makebook :rank 46 :author "Milan Kundera" :title "The Unbearable Lightness of Being") | |
(makebook :rank 47 :author "Sebastian Faulks" :title "Birdsong") | |
(makebook :rank 48 :author "E.M. Forster" :title "Howard's End") | |
(makebook :rank 49 :author "Evelyn Waugh" :title "Brideshead Revisited") | |
(makebook :rank 50 :author "Vikram Seth" :title "A Suitable Boy") | |
(makebook :rank 51 :author "Frank Herbert" :title "Dune") | |
(makebook :rank 52 :author "John Irvine" :title "A Prayer for Owen Meaney") | |
(makebook :rank 53 :author "Patrick Suskind" :title "Perfume") | |
(makebook :rank 54 :author "Boris Pasternak" :title "Doctor Zhivago") | |
(makebook :rank 55 :author "Mervyn Peake" :title "Gormenghast") | |
(makebook :rank 56 :author "Laurie Lee" :title "Cider with Rosie") | |
(makebook :rank 57 :author "Sylvia Plath" :title "The Bell Jar") | |
(makebook :rank 58 :author "Margaret Atwood" :title "The Handmaid's Tale") | |
(makebook :rank 59 :author "Vera Brittain" :title "Testament of Youth") | |
(makebook :rank 60 :author "John Fowlws" :title "The Magus") | |
(makebook :rank 61 :author "Graham Greene" :title "Brighton Rock") | |
(makebook :rank 62 :author "Robert Tressell" :title "The Ragged-Trousered Philanthropists") | |
(makebook :rank 63 :author "Mikhail Bugakov" :title "The Master and Margarita") | |
(makebook :rank 64 :author "Armistead Maupin" :title "Tales from the City") | |
(makebook :rank 65 :author "John Fowles" :title "The French Lieutenant's Woman") | |
(makebook :rank 66 :author "Louis de Bernieres" :title "Captain Corelli's Mandolin") | |
(makebook :rank 67 :author "Kurt Vonnegut" :title "Slaughterhouse Five") | |
(makebook :rank 68 :author "Robert Persig" :title "Zen and the Art of Motorcycle Maintenance") | |
(makebook :rank 69 :author "E.M. Forster" :title "A Room with a View") | |
(makebook :rank 70 :author "Kingsley Amis" :title "Lucky Jim") | |
(makebook :rank 71 :author "Stephen King" :title "It") | |
(makebook :rank 72 :author "Graham Greene" :title "The Power and the Glory") | |
(makebook :rank 73 :author "Stephen King" :title "The Stand") | |
(makebook :rank 74 :author "Erich Maria Remarque" :title "All Quiet on the Western Front") | |
(makebook :rank 75 :author "Roddy Doyle" :title "Paddy Clarke Ha Ha Ha") | |
(makebook :rank 76 :author "Roald Dahl" :title "Matilda") | |
(makebook :rank 77 :author "Bret Easton Ellis" :title "American Psycho") | |
(makebook :rank 78 :author "Hunter S. Thompson" :title "Fear and Loathing in Las Vegas") | |
(makebook :rank 79 :author "Stephen Hawking" :title "A Brief History of Time") | |
(makebook :rank 80 :author "Roald Dahl" :title "James and the Giant Peach") | |
(makebook :rank 81 :author "D.H. Lawrence" :title "Lady Chatterley's Lover") | |
(makebook :rank 82 :author "Tom Wolfe" :title "The Bonfire of the Vanities") | |
(makebook :rank 83 :author "Delia Smith" :title "Complete Cookery Course") | |
(makebook :rank 84 :author "Brian Keenan" :title "An Evil Cradling") | |
(makebook :rank 85 :author "D.H. Lawrence" :title "The Rainbow") | |
(makebook :rank 86 :author "George Orwell" :title "Down and Out in Paris and London") | |
(makebook :rank 87 :author "Arthur C. Clarke" :title "2001 - A Space Odyssey") | |
(makebook :rank 88 :author "Gunter Grass" :title "The Tin Drum") | |
(makebook :rank 89 :author "Alexander Solzhenitsyn" :title "A Day in the Life of Ivan Denisovich") | |
(makebook :rank 90 :author "Nelson Mandela" :title "Long Walk to Freedom") | |
(makebook :rank 91 :author "Richard Dawkins" :title "The Selfish Gene") | |
(makebook :rank 92 :author "Michael Crichton" :title "Jurassic Park") | |
(makebook :rank 93 :author "Lawrence Durrell" :title "The Alexandria Quartet") | |
(makebook :rank 94 :author "Alan Paton" :title "Cry the Beloved Country") | |
(makebook :rank 95 :author "Nick Hornby" :title "High Fidelity") | |
(makebook :rank 96 :author "Roddy Doyle" :title "The Van") | |
(makebook :rank 97 :author "Roald Dahl" :title "The BFG") | |
(makebook :rank 98 :author "Anthony Burgess" :title "Earthly Powers") | |
(makebook :rank 99 :author "Robert Graves" :title "I, Claudius") | |
(makebook :rank 100 :author "Nicholas Evans" :title "The Horse Whisperer")]) | |
(def | |
^{:books/url "http://www.modernlibrary.com/top-100/radcliffes-rival-100-best-novels-list/"} | |
radcliffes [ | |
(makebook :title "The Great Gatsby" :author "F. Scott Fitzgerald" :rank 1) | |
(makebook :title "The Catcher in the Rye" :author "J.D. Salinger" :rank 2) | |
(makebook :title "The Grapes of Wrath" :author "John Steinbeck" :rank 3) | |
(makebook :title "To Kill a Mockingbird" :author "Harper Lee" :rank 4) | |
(makebook :title "The Color Purple" :author "Alice Walker" :rank 5) | |
(makebook :title "Ulysses" :author "James Joyce" :rank 6) | |
(makebook :title "Beloved" :author "Toni Morrison" :rank 7) | |
(makebook :title "The Lord of the Flies" :author "William Golding" :rank 8) | |
(makebook :title "1984" :author "George Orwell" :rank 9) | |
(makebook :title "The Sound and the Fury" :author "William Faulkner" :rank 10) | |
(makebook :title "Lolita" :author "Vladmir Nabokov" :rank 11) | |
(makebook :title "Of Mice and Men" :author "John Steinbeck" :rank 12) | |
(makebook :title "Charlotte's Web" :author "E.B. White" :rank 13) | |
(makebook :title "A Portrait of the Artist as a Young Man" :author "James Joyce" :rank 14) | |
(makebook :title "Catch-22" :author "Joseph Heller" :rank 15) | |
(makebook :title "Brave New World" :author "Aldous Huxley" :rank 16) | |
(makebook :title "Animal Farm" :author "George Orwell" :rank 17) | |
(makebook :title "The Sun Also Rises" :author "Ernest Hemingway" :rank 18) | |
(makebook :title "As I Lay Dying" :author "William Faulkner" :rank 19) | |
(makebook :title "A Farewell to Arms" :author "Ernest Hemingway" :rank 20) | |
(makebook :title "Heart of Darkness" :author "Joseph Conrad" :rank 21) | |
(makebook :title "Winnie-the-Pooh" :author "A.A. Milne" :rank 22) | |
(makebook :title "Their Eyes Were Watching God" :author "Zora Neale Hurston" :rank 23) | |
(makebook :title "Invisible Man" :author "Ralph Ellison" :rank 24) | |
(makebook :title "Song of Solomon" :author "Toni Morrison" :rank 25) | |
(makebook :title "Gone with the Wind" :author "Margaret Mitchell" :rank 26) | |
(makebook :title "Native Son" :author "Richard Wright" :rank 27) | |
(makebook :title "One Flew Over the Cuckoo's Nest" :author "Ken Kesey" :rank 28) | |
(makebook :title "Slaughterhouse-Five" :author "Kurt Vonnegut" :rank 29) | |
(makebook :title "For Whom the Bell Tolls" :author "Ernest Hemingway" :rank 30) | |
(makebook :title "On the Road" :author "Jack Kerouac" :rank 31) | |
(makebook :title "The Old Man and the Sea" :author "Ernest Hemingway" :rank 32) | |
(makebook :title "The Call of the Wild" :author "Jack London" :rank 33) | |
(makebook :title "To the Lighthouse" :author "Virginia Woolf" :rank 34) | |
(makebook :title "Portrait of a Lady" :author "Henry James" :rank 35) | |
(makebook :title "Go Tell it on the Mountain" :author "James Baldwin" :rank 36) | |
(makebook :title "The World According to Garp" :author "John Irving" :rank 37) | |
(makebook :title "All the King's Men" :author "Robert Penn Warren" :rank 38) | |
(makebook :title "A Room with a View" :author "E.M. Forster" :rank 39) | |
(makebook :title "The Lord of the Rings" :author "J.R.R. Tolkien" :rank 40) | |
(makebook :title "Schindler's List" :author "Thomas Keneally" :rank 41) | |
(makebook :title "The Age of Innocence" :author "Edith Wharton" :rank 42) | |
(makebook :title "The Fountainhead" :author "Ayn Rand" :rank 43) | |
(makebook :title "Finnegans Wake" :author "James Joyce" :rank 44) | |
(makebook :title "The Jungle" :author "Upton Sinclair" :rank 45) | |
(makebook :title "Mrs. Dalloway" :author "Virginia Woolf" :rank 46) | |
(makebook :title "The Wonderful Wizard of Oz" :author "L. Frank Baum" :rank 47) | |
(makebook :title "Lady Chatterley's Lover" :author "D.H. Lawrence" :rank 48) | |
(makebook :title "A Clockwork Orange" :author "Anthony Burgess" :rank 49) | |
(makebook :title "The Awakening" :author "Kate Chopin" :rank 50) | |
(makebook :title "My Antonia" :author "Willa Cather" :rank 51) | |
(makebook :title "Howards End" :author "E.M. Forster" :rank 52) | |
(makebook :title "In Cold Blood" :author "Truman Capote" :rank 53) | |
(makebook :title "Franny and Zooey" :author "J.D. Salinger" :rank 54) | |
(makebook :title "The Satanic Verses" :author "Salman Rushdie" :rank 55) | |
(makebook :title "Jazz" :author "Toni Morrison" :rank 56) | |
(makebook :title "Sophie's Choice" :author "William Styron" :rank 57) | |
(makebook :title "Absalom, Absalom!" :author "William Faulkner" :rank 58) | |
(makebook :title "A Passage to India" :author "E.M. Forster" :rank 59) | |
(makebook :title "Ethan Frome" :author "Edith Wharton" :rank 60) | |
(makebook :title "A Good Man Is Hard to Find" :author "Flannery O'Connor" :rank 61) | |
(makebook :title "Tender Is the Night" :author "F. Scott Fitzgerald" :rank 62) | |
(makebook :title "Orlando" :author "Virginia Woolf" :rank 63) | |
(makebook :title "Sons and Lovers" :author "D.H. Lawrence" :rank 64) | |
(makebook :title "Bonfire of the Vanities" :author "Tom Wolfe" :rank 65) | |
(makebook :title "Cat's Cradle" :author "Kurt Vonnegut" :rank 66) | |
(makebook :title "A Separate Peace" :author "John Knowles" :rank 67) | |
(makebook :title "Light in August" :author "William Faulkner" :rank 68) | |
(makebook :title "The Wings of the Dove" :author "Henry James" :rank 69) | |
(makebook :title "Things Fall Apart" :author "Chinua Achebe" :rank 70) | |
(makebook :title "Rebecca" :author "Daphne du Maurier" :rank 71) | |
(makebook :title "A Hitchhiker's Guide to the Galaxy" :author "Douglas Adams" :rank 72) | |
(makebook :title "Naked Lunch" :author "William S. Burroughs" :rank 73) | |
(makebook :title "Brideshead Revisited" :author "Evelyn Waugh" :rank 74) | |
(makebook :title "Women in Love" :author "D.H. Lawrence" :rank 75) | |
(makebook :title "Look Homeward, Angel" :author "Thomas Wolfe" :rank 76) | |
(makebook :title "In Our Time" :author "Ernest Hemingway" :rank 77) | |
(makebook :title "The Autobiography of Alice B. Tokias" :author "Gertrude Stein" :rank 78) | |
(makebook :title "The Maltese Falcon" :author "Dashiell Hammett" :rank 79) | |
(makebook :title "The Naked and the Dead" :author "Norman Mailer" :rank 80) | |
(makebook :title "Wide Sargasso Sea" :author "Jean Rhys" :rank 81) | |
(makebook :title "White Noise" :author "Don DeLillo" :rank 82) | |
(makebook :title "O Pioneers!" :author "Willa Cather" :rank 83) | |
(makebook :title "Tropic of Cancer" :author "Henry Miller" :rank 84) | |
(makebook :title "The War of the Worlds" :author "H.G. Wells" :rank 85) | |
(makebook :title "Lord Jim" :author "Joseph Conrad" :rank 86) | |
(makebook :title "The Bostonians" :author "Henry James" :rank 87) | |
(makebook :title "An American Tragedy" :author "Theodore Dreiser" :rank 88) | |
(makebook :title "Death Comes for the Archbishop" :author "Willa Cather" :rank 89) | |
(makebook :title "The Wind in the Willows" :author "Kenneth Grahame" :rank 90) | |
(makebook :title "This Side of Paradise" :author "F. Scott Fitzgerald" :rank 91) | |
(makebook :title "Atlas Shrugged" :author "Ayn Rand" :rank 92) | |
(makebook :title "The French Lieutenant's Woman" :author "John Fowles" :rank 93) | |
(makebook :title "Babbitt" :author "Sinclair Lewis" :rank 94) | |
(makebook :title "Kim" :author "Rudyard Kipling" :rank 95) | |
(makebook :title "The Beautiful and the Damned" :author "F. Scott Fitzgerald" :rank 96) | |
(makebook :title "Rabbit, Run" :author "John Updike" :rank 97) | |
(makebook :title "Where Angels Fear to Tread" :author "E.M. Forster" :rank 98) | |
(makebook :title "Main Street" :author "Sinclair Lewis" :rank 99) | |
(makebook :title "Midnight's Children" :author "Salman Rushdie" :rank 100)]) | |
(def | |
^{:books/url "http://www.infoplease.com/ipea/A0776722.html#ixzz1VARD6XjO"} | |
random-house [ | |
(makebook :title "Ulysses" :author "James Joyce" :year 1922 :rank 1) | |
(makebook :author "F. Scott Fitzgerald" :year 1925 :rank 2 :title "The Great Gatsby") | |
(makebook :author "James Joyce" :year 1916 :rank 3 :title "A Portrait of the Artist as a Young Man") | |
(makebook :author "Vladimir Nabokov" :year 1958 :rank 4 :title "Lolita") | |
(makebook :author "Aldous Huxley" :year 1932 :rank 5 :title "Brave New World") | |
(makebook :author "William Faulkner" :year 1929 :rank 6 :title "The Sound and the Fury") | |
(makebook :author "Joseph Heller" :year 1961 :rank 7 :title "Catch-22") | |
(makebook :author "Arthur Koestler" :year 1941 :rank 8 :title "Darkness at Noon") | |
(makebook :author "D. H. Lawrence" :year 1913 :rank 9 :title "Sons and Lovers") | |
(makebook :author "John Steinbeck" :year 1939 :rank 10 :title "The Grapes of Wrath") | |
(makebook :author "Malcolm Lowry" :year 1947 :rank 11 :title "Under the Volcano") | |
(makebook :author "Samuel Butler" :year 1903 :rank 12 :title "The Way of All Flesh") | |
(makebook :author "George Orwell" :year 1949 :rank 13 :title "1984") | |
(makebook :author "Robert Graves" :year 1934 :rank 14 :title "I, Claudius") | |
(makebook :author "Virginia Woolf" :year 1927 :rank 15 :title "To the Lighthouse") | |
(makebook :author "Theodore Dreiser" :year 1925 :rank 16 :title "An American Tragedy") | |
(makebook :author "Carson McCullers" :year 1940 :rank 17 :title "The Heart Is a Lonely Hunter") | |
(makebook :author "Kurt Vonnegut" :year 1969 :rank 18 :title "Slaughterhouse-Five") | |
(makebook :author "Ralph Ellison" :year 1952 :rank 19 :title "Invisible Man") | |
(makebook :author "Richard Wright" :year 1940 :rank 20 :title "Native Son") | |
(makebook :author "Saul Bellow" :year 1959 :rank 21 :title "Henderson the Rain King") | |
(makebook :author "John O'Hara" :year 1934 :rank 22 :title "Appointment in Samarra") | |
(makebook :author "John Dos Passos" :year 1937 :rank 23 :title "U.S.A. (trilogy)") | |
(makebook :author "Sherwood Anderson" :year 1919 :rank 24 :title "Winesburg, Ohio") | |
(makebook :author "E. M. Forster" :year 1924 :rank 25 :title "A Passage to India") | |
(makebook :author "Henry James" :year 1902 :rank 26 :title "The Wings of the Dove") | |
(makebook :author "Henry James" :year 1903 :rank 27 :title "The Ambassadors") | |
(makebook :author "F. Scott Fitzgerald" :year 1934 :rank 28 :title "Tender Is the Night") | |
(makebook :author "James T. Farrell" :year 1935 :rank 29 :title "The Studs Lonigan Trilogy") | |
(makebook :author "Ford Madox Ford" :year 1915 :rank 30 :title "The Good Soldier") | |
(makebook :author "George Orwell" :year 1946 :rank 31 :title "Animal Farm") | |
(makebook :author "Henry James" :year 1904 :rank 32 :title "The Golden Bowl") | |
(makebook :author "Theodore Dreiser" :year 1900 :rank 33 :title "Sister Carrie") | |
(makebook :author "Evelyn Waugh" :year 1934 :rank 34 :title "A Handful of Dust") | |
(makebook :author "William Faulkner" :year 1930 :rank 35 :title "As I Lay Dying") | |
(makebook :author "Robert Penn Warren" :year 1946 :rank 36 :title "All the King's Men") | |
(makebook :author "Thornton Wilder" :year 1927 :rank 37 :title "The Bridge of San Luis Rey") | |
(makebook :author "E. M. Forster" :year 1910 :rank 38 :title "Howards End") | |
(makebook :author "James Baldwin" :year 1953 :rank 39 :title "Go Tell It on the Mountain") | |
(makebook :author "Graham Greene" :year 1948 :rank 40 :title "The Heart of the Matter") | |
(makebook :author "William Golding" :year 1954 :rank 41 :title "Lord of the Flies") | |
(makebook :author "James Dickey" :year 1969 :rank 42 :title "Deliverance") | |
(makebook :author "Anthony Powell" :year 1975 :rank 43 :title "A Dance to the Music of Time (series)") | |
(makebook :author "Aldous Huxley" :year 1928 :rank 44 :title "Point Counter Point") | |
(makebook :author "Ernest Hemingway" :year 1926 :rank 45 :title "The Sun Also Rises") | |
(makebook :author "Joseph Conrad" :year 1907 :rank 46 :title "The Secret Agent") | |
(makebook :author "Joseph Conrad" :year 1904 :rank 47 :title "Nostromo") | |
(makebook :author "D. H. Lawrence" :year 1915 :rank 48 :title "The Rainbow") | |
(makebook :author "D. H. Lawrence" :year 1921 :rank 49 :title "Women in Love") | |
(makebook :author "Henry Miller" :year 1934 :rank 50 :title "Tropic of Cancer") | |
(makebook :author "Norman Mailer" :year 1948 :rank 51 :title "The Naked and the Dead") | |
(makebook :author "Philip Roth" :year 1969 :rank 52 :title "Portnoy's Complaint") | |
(makebook :author "Vladimir Nabokov" :year 1962 :rank 53 :title "Pale Fire") | |
(makebook :author "William Faulkner" :year 1932 :rank 54 :title "Light in August") | |
(makebook :author "Jack Kerouac" :year 1957 :rank 55 :title "On the Road") | |
(makebook :author "Dashiell Hammett" :year 1930 :rank 56 :title "The Maltese Falcon") | |
(makebook :author "Ford Madox Ford" :year 1950 :rank 57 :title "Parade's End") | |
(makebook :author "Edith Wharton" :year 1920 :rank 58 :title "The Age of Innocence") | |
(makebook :author "Max Beerbohm" :year 1911 :rank 59 :title "Zuleika Dobson") | |
(makebook :author "Walker Percy" :year 1961 :rank 60 :title "The Moviegoer") | |
(makebook :author "Willa Cather" :year 1927 :rank 61 :title "Death Comes for the Archbishop") | |
(makebook :author "James Jones" :year 1951 :rank 62 :title "From Here to Eternity") | |
(makebook :author "John Cheever" :year 1957 :rank 63 :title "The Wapshot Chronicles") | |
(makebook :author "J. D. Salinger" :year 1951 :rank 64 :title "The Catcher in the Rye") | |
(makebook :author "Anthony Burgess" :year 1962 :rank 65 :title "A Clockwork Orange") | |
(makebook :author "W. Somerset Maugham" :year 1915 :rank 66 :title "Of Human Bondage") | |
(makebook :author "Joseph Conrad" :year 1902 :rank 67 :title "Heart of Darkness") | |
(makebook :author "Sinclair Lewis" :year 1920 :rank 68 :title "Main Street") | |
(makebook :author "Edith Wharton" :year 1905 :rank 69 :title "The House of Mirth") | |
(makebook :author "Lawrence Durrell" :year 1960 :rank 70 :title "The Alexandria Quartet") | |
(makebook :author "Richard Hughes" :year 1929 :rank 71 :title "A High Wind in Jamaica") | |
(makebook :author "V. S. Naipaul" :year 1961 :rank 72 :title "A House for Mr. Biswas") | |
(makebook :author "Nathanael West" :year 1939 :rank 73 :title "The Day of the Locust") | |
(makebook :author "Ernest Hemingway" :year 1929 :rank 74 :title "A Farewell to Arms") | |
(makebook :author "Evelyn Waugh" :year 1938 :rank 75 :title "Scoop") | |
(makebook :author "Muriel Spark" :year 1961 :rank 76 :title "The Prime of Miss Jean Brodie") | |
(makebook :author "James Joyce" :year 1939 :rank 77 :title "Finnegans Wake") | |
(makebook :author "Rudyard Kipling" :year 1901 :rank 78 :title "Kim") | |
(makebook :author "E. M. Forster" :year 1908 :rank 79 :title "A Room with a View") | |
(makebook :author "Evelyn Waugh" :year 1945 :rank 80 :title "Brideshead Revisited") | |
(makebook :author "Saul Bellow" :year 1953 :rank 81 :title "The Adventures of Augie March") | |
(makebook :author "Wallace Stegner" :year 1971 :rank 82 :title "Angle of Repose") | |
(makebook :author "V. S. Naipaul" :year 1979 :rank 83 :title "A Bend in the River") | |
(makebook :author "Elizabeth Bowen" :year 1938 :rank 84 :title "The Death of the Heart") | |
(makebook :author "Joseph Conrad" :year 1900 :rank 85 :title "Lord Jim") | |
(makebook :author "E. L. Doctorow" :year 1975 :rank 86 :title "Ragtime") | |
(makebook :author "Arnold Bennett" :year 1908 :rank 87 :title "The Old Wives' Tale") | |
(makebook :author "Jack London" :year 1903 :rank 88 :title "The Call of the Wild") | |
(makebook :author "Henry Green" :year 1945 :rank 89 :title "Loving") | |
(makebook :author "Salman Rushdie" :year 1981 :rank 90 :title "Midnight's Children") | |
(makebook :author "Erskine Caldwell" :year 1933 :rank 91 :title "Tobacco Road") | |
(makebook :author "William Kennedy" :year 1983 :rank 92 :title "Ironweed") | |
(makebook :author "John Fowles" :year 1966 :rank 93 :title "The Magus") | |
(makebook :author "Jean Rhys" :year 1966 :rank 94 :title "Wide Sargasso Sea") | |
(makebook :author "Iris Murdoch" :year 1954 :rank 95 :title "Under the Net") | |
(makebook :author "William Styron" :year 1979 :rank 96 :title "Sophie's Choice") | |
(makebook :author "Paul Bowles" :year 1949 :rank 97 :title "The Sheltering Sky") | |
(makebook :author "James M. Cain" :year 1934 :rank 98 :title "The Postman Always Rings Twice") | |
(makebook :author "J. P. Donleavy" :year 1955 :rank 99 :title "The Ginger Man") | |
(makebook :author "Booth Tarkington" :year 1918 :rank 100 :title "The Magnificent Ambersons")]) | |
(defn like [s1 s2] | |
(re-matches (re-pattern (str ".*" s2 ".*")) s1)) | |
(defn matches [s re] | |
(re-matches (re-pattern re) s)) | |
(defmacro showbooks [bookvec filter-expr] | |
`(doseq [~'book (vec (~'getbooks ~bookvec ~filter-expr))] | |
(printbook ~'book))) | |
(defmacro getbooks [bookvec filter-expr] | |
`(for [~'book ~bookvec :when ~filter-expr] ~'book)) | |
(defn showfn [bookvec filter-function display-function] | |
(doseq [b bookvec :when (fn [b] (filter-function b))] | |
(display-function b))) | |
(defmacro top [num] | |
`(<= (:rank ~'book) ~num)) | |
(defmacro from-to [low high] | |
`(and (<= (:rank ~'book) ~high) (>= (:rank ~'book) ~low))) | |
(defmacro author-is [author] | |
`(= (:author ~'book) ~author)) | |
(defmacro author-like [author-re] | |
`(like (:author ~'book) (str "(?i)" ~author-re))) | |
(defmacro title-like [title-re] | |
`(like (:title ~'book) ~title-re)) | |
(defn printbook [b] | |
(println (:rank b) "-" (:title b) "-" (:author b) "-" (str (:year b)))) | |
(defmacro number [num] | |
`(from-to ~num ~num)) | |
(defmacro all [] | |
`(= 1 1)) | |
(def | |
banned [ | |
(makebook :title "The Great Gatsby" :author "F. Scott Fitzgerald") | |
(makebook :title "The Catcher in the Rye" :author "J.D. Salinger") | |
(makebook :title "The Grapes of Wrath" :author "John Steinbeck") | |
(makebook :title "To Kill a Mockingbird" :author "Harper Lee") | |
(makebook :title "The Color Purple" :author "Alice Walker") | |
(makebook :title "Ulysses" :author "James Joyce") | |
(makebook :title "Beloved" :author "Toni Morrison") | |
(makebook :title "The Lord of the Flies" :author "William Golding") | |
(makebook :title "1984" :author "George Orwell") | |
(makebook :title "Lolita" :author "Vladmir Nabokov") | |
(makebook :title "Of Mice and Men" :author "John Steinbeck") | |
(makebook :title "Catch-22" :author "Joseph Heller") | |
(makebook :title "Brave New World" :author "Aldous Huxley") | |
(makebook :title "Animal Farm" :author "George Orwell") | |
(makebook :title "The Sun Also Rises" :author "Ernest Hemingway") | |
(makebook :title "As I Lay Dying" :author "William Faulkner") | |
(makebook :title "A Farewell to Arms" :author "Ernest Hemingway") | |
(makebook :title "Their Eyes Were Watching God" :author "Zora Neale Hurston") | |
(makebook :title "Invisible Man" :author "Ralph Ellison") | |
(makebook :title "Song of Solomon" :author "Toni Morrison") | |
(makebook :title "Gone with the Wind" :author "Margaret Mitchell") | |
(makebook :title "Native Son" :author "Richard Wright") | |
(makebook :title "One Flew Over the Cuckoo's Nest" :author "Ken Kesey") | |
(makebook :title "Slaughterhouse-Five" :author "Kurt Vonnegut") | |
(makebook :title "For Whom the Bell Tolls" :author "Ernest Hemingway") | |
(makebook :title "The Call of the Wild" :author "Jack London") | |
(makebook :title "Go Tell it on the Mountain" :author "James Baldwin") | |
(makebook :title "All the King's Men" :author "Robert Penn Warren") | |
(makebook :title "The Lord of the Rings" :author "J.R.R. Tolkien") | |
(makebook :title "The Jungle" :author "Upton Sinclair") | |
(makebook :title "Lady Chatterley's Lover" :author "D.H. Lawrence") | |
(makebook :title "A Clockwork Orange" :author "Anthony Burgess") | |
(makebook :title "The Awakening" :author "Kate Chopin") | |
(makebook :title "In Cold Blood" :author "Truman Capote") | |
(makebook :title "The Satanic Verses" :author "Salman Rushdie") | |
(makebook :title "Sophie's Choice" :author "William Styron") | |
(makebook :title "Sons and Lovers" :author "D.H. Lawrence") | |
(makebook :title "Cat's Cradle" :author "Kurt Vonnegut") | |
(makebook :title "A Separate Peace" :author "John Knowles") | |
(makebook :title "Naked Lunch" :author "William S. Burroughs") | |
(makebook :title "Brideshead Revisited" :author "Evelyn Waugh") | |
(makebook :title "Women in Love" :author "D.H. Lawrence") | |
(makebook :title "The Naked and the Dead" :author "Norman Mailer") | |
(makebook :title "Tropic of Cancer" :author "Henry Miller") | |
(makebook :title "An American Tragedy" :author "Theodore Dreiser") | |
(makebook :title "Rabbit, Run" :author "John Updike")]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment