TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Writing a Programming Book in 2021

186 点作者 wilsonfiifi大约 4 年前

12 条评论

MrPowers大约 4 年前
I wrote a couple of books recently and have some tips for aspiring authors:<p>* Start by blogging. Try to get thousands of daily pageviews with an average time on page &gt; 5 minutes. Objectively verify you&#x27;re able to write content that&#x27;s engaging.<p>* Try to fill a niche. My book is focused on practical advice for getting productive with Spark using the Scala API quickly. There are other books that cover theory, discuss all 4 language APIs simultaneously, and are API documentation narratives (e.g. Chapter 4 will cover all the DataFrame methods in alphabetical order). Most people don&#x27;t have the attention span for huge books.<p>* Target middle school reading level. Short sentences &amp; simple words. Technical audiences want information and don&#x27;t care much about literary prose.<p>* Organize your code snippets in a repo, so it&#x27;s easy to update your book<p>I got some offers from publishers, but went the self-publishing route cause I didn&#x27;t think that a publisher could give too much valuable feedback on such a technical topic. Lots of my blog readers told me my blogs are easy to follow, so I felt confident I didn&#x27;t need a professional editor. Publishers pay 20% royalties and self publishing lets you keep 80%+, so you should only go with a publisher if they can add that extra value.<p>Writing a book was a great experience for me. It&#x27;s an easy way to train folks who are new to Spark. Several folks have emailed me, told me they can&#x27;t afford the book, and I&#x27;ve sent them free copies. Don&#x27;t think writing books is a great way to make money, but it&#x27;s great if you have altruistic motives.
评论 #27131532 未加载
评论 #27134961 未加载
评论 #27133145 未加载
评论 #27132302 未加载
评论 #27131696 未加载
评论 #27133327 未加载
评论 #27131131 未加载
onion2k大约 4 年前
The point about Credibility is interesting. There&#x27;s something about someone who&#x27;s written a technical book that automatically seems impressive just because writing a book is hard, and it&#x27;s easy to assume that the person knows a lot. A long time ago I used to do technical review for a publisher on books about code. It was pretty obvious that some authors didn&#x27;t really know what they were talking about. They knew enough to write something, but there were always <i>a lot</i> of mistakes.<p>I think many technical books are written to act as a &#x27;proof&#x27; that the author is credible and knows their topic well rather than as an exercise in serving the reader or an attempt to make money. Tech authors know that they&#x27;ve not going to make much. It&#x27;s more an exercise in vanity and improving job prospects. The author doesn&#x27;t really need to be <i>right</i>. Especially &quot;Beginner&#x27;s guide to X&quot; or &quot;Learn X in 24 hours&quot; books, experienced and knowledgable developers won&#x27;t be reading the book to criticise it, and new developers who buy it won&#x27;t know it&#x27;s poorly written, so an author can write any old junk and still claim to be an expert. Consequently I&#x27;ve stopped being particularly impressed by people who have authored books on their resume.
评论 #27130638 未加载
评论 #27130932 未加载
评论 #27130846 未加载
评论 #27130840 未加载
评论 #27134264 未加载
Syzygies大约 4 年前
The programming book genre needs to be redefined.<p>In college I was nearly thrown out of my math major, after giving no evidence of having started a year-in-a-semester modern analysis course, with three weeks to go. (I had been busy with a disastrous International Economics computer simulation using Fortran punched cards. Why, when Dukakis ran for president, did no one ask if &quot;the world blew up his year?&quot;) I am forever grateful that &quot;Baby Rudin&quot; is such a thin book.<p>A minor in English taught me that genres are not inevitable. They are cultural choices.<p>Every year I get more comfortable recognizing I&#x27;m neurodiverse (substitute your favorite ADHD acronym) and so are many of my best students. Recognizing this makes me a better professor. Math notation, for example, is simply someone else&#x27;s bad computer code. Don&#x27;t blame yourself as you struggle to read it, and realize that everyone who succeeds has vivid daydreams that bear no resemblence to the bad code.<p>I loathe nearly every programming book I&#x27;ve ever read. I live in fear that I&#x27;ll turn the page and be writing a music player. What&#x27;s that nugget about &quot;never write a language for someone in their first week?&quot; REPL examples always include all beginner &quot;bird track&quot; prompts, when anyone with an aesthetic sense customizes their REPL in the first week to hide all noise and syntax-color output. When I&#x27;m feeling an ADHD haze I can barely find the code samples on a programming book page.<p>What I&#x27;ve learned as a professor is that everyone feels this resistance. Some acknowledge it. Planes don&#x27;t crash because we minimize this resistance in the cockpit. The neurodiverse are the canaries in the mine shaft.<p>I&#x27;ve learned dozens of languages, and bought countless programming books. &quot;The C Programming Language&quot; by Kernighan and Ritchie remains my favorite, a mercifully thin book like &quot;Baby Rudin&quot;.<p>Learning a language quickly, one learns how each chess piece moves, and still wonders how to put together programs effectively. Just as the greats in any intellectual discipline insist on only reading original works, the most gifted programmers learn by reading code.<p>I also attempt to learn human languages as a hobby. The great difficulties I experience give me insights into teaching. What is most effective is a staged progression of readers, with parallel text nearby, till one can learn to read unassisted in the language. If the content can be anticipated (such as the wonderfully repetitive &quot;Sapiens&quot; in various translations) all the better. If there&#x27;s also an audiobook, all the better.<p>A programming book should teach a language through a sequence of small, complete code samples, so clearly delineated that a scuba diver 30 meters deep can work out what&#x27;s the code, what&#x27;s the blather. The main activity of reading the book should be puzzling out how each code fragment works. Skip the &quot;word problems&quot; and focus on simple combinatorial tasks that exercise the language.
评论 #27137671 未加载
评论 #27133421 未加载
ModernMech大约 4 年前
I think one piece of advise missing here is: define your value add upfront. There are 1000 books on Go out there. What are you bringing to the table that others don’t?<p>The other piece of advice I have is: hire an editor and fact checker. The last thing you want to do is put substandard quality content out there filled with bad grammar and errors. This post seems to suggest that by self-publishing, the author did the task of editing themselves. I would say this is not advised if you want the best results. Hire a third party to do this work for you instead of doing it yourself. They will bring a fresh perspective to your work and help you see things that you cannot.
wccrawford大约 4 年前
&gt;You don&#x27;t really understand something unless you can explain it to your grandma<p>I&#x27;ve seen a lot of blog posts written for this reason, and they&#x27;re all pretty crappy. I really hope that wasn&#x27;t seriously a reason to write a book.
评论 #27130251 未加载
评论 #27133659 未加载
lelanthran大约 4 年前
&gt; Stay to your index &gt; &gt; A book has a beginning and an ending. Remember that. Write down your index of contents before you start writing.<p>The table of contents is typically not an index. An index is something else found at the end of the book.
评论 #27130532 未加载
strzibny大约 4 年前
I think it&#x27;s a decent article. I mostly agree.<p>But I want to say that I wish the credibility is in reverse. You should first be credible enough for writing, then you can boost it further for having it finished and well received. Just finishing a technical book is not enough.<p>I am too finishing a self published book[0] so I am very interested in other self-published cases. I miss some sales numbers in the article or advice on marketing strategy.<p>If someone is interested, I just shared how the first month of selling went for my book[1] (spoiler: pretty well for unfinished book). I will continue doing this, because I think it&#x27;s super helpful for others thinking about it.<p>Writing a good book is HARD. Marketing it might be even harder. Most authors will be net-negative considering salaried work, so share your numbers!<p>[0] <a href="https:&#x2F;&#x2F;deploymentfromscratch.com" rel="nofollow">https:&#x2F;&#x2F;deploymentfromscratch.com</a><p>[1] <a href="https:&#x2F;&#x2F;www.indiehackers.com&#x2F;post&#x2F;today-is-my-first-ever-gumroad-pay-day-over-2000-in-sales-c9af9c5fa5" rel="nofollow">https:&#x2F;&#x2F;www.indiehackers.com&#x2F;post&#x2F;today-is-my-first-ever-gum...</a>
tfp137大约 4 年前
<i>Self-publishing has always been an option for authors. Some publishing houses offer you resources to publish your work. You simply pay them and they review and print your book. It seems to be a fair arrangement. However, after five minutes in Google, you will find out that many self-published authors had terrible experiences or were scammed. Finding a decent and professional publishing house requires time. You cannot trust the first one you find in Google.</i><p>Those &quot;self-publishing companies&quot; are often next-generation vanity press. Then again, bottom tier traditional publishing— and the dangerous part is, this includes bottom-tier deals from &quot;Big 5&quot; imprints— are basically vanity press as well.<p>The number of first-time authors who get traditional deals actually worth taking (the kind that come with 6-figure marketing budgets and TV spots delivered in-hand) is probably in the double digits per year— it&#x27;s not that hard to &quot;get an agent&quot; if you&#x27;re willing to take abuse, but 98% of literary agents have no real connections but serve as an HR wall, existing solely to filter out the deserving perma-slush, that will probably be replaced with machine learning algorithms soon.<p>Publishing gives writers a possibly necessary but very unpleasant introduction to the reality of commerce— there are so, so many people out there looking to get as much as they can (money) and give as little as possible. This applies when you pay thousands of dollars to a &quot;self-publishing company&quot; and get work (cover design, editing, et al) that a high schooler could have done... but it also applies when you sign away your rights to a &quot;Big 5&quot; for a piddly advance and no marketing.<p>I think the game&#x27;s very different for programming books than it is for, say, fiction. Generally, people don&#x27;t write books about Python because they think they&#x27;re going to quit their day jobs. At the same time, people who can write even passable programming books are fairly few in number... whereas people who can write passable novels that could in theory become the next <i>50 Shades</i> are commonplace (although people who can write <i>good</i> novels are very rare).<p>It&#x27;s impossible to say what it requires not to get scammed in publishing— you have to take some risks, and who can say what risks are right to take?— but a good first step is to accept the very real possibility that you do everything right and still don&#x27;t sell more than a few dozen copies. Sometimes terrible books sell (<i>50 Shades</i>) and sometimes great books go ignored for thirty years.
shawnps大约 4 年前
We&#x27;re enjoying LeanPub for publishing Production Go (<a href="https:&#x2F;&#x2F;leanpub.com&#x2F;productiongo" rel="nofollow">https:&#x2F;&#x2F;leanpub.com&#x2F;productiongo</a>).<p>You can write in Markdown, and sync with git. You can set a minimum price, but in our experience people often pay more.<p>A couple of notes:<p><pre><code> 1. The ability to have a book be &quot;in progress&quot; is not necessarily a good thing, because you can get stuck in unfinished mode (like our book :(). 2. You can publish a print-ready PDF (https:&#x2F;&#x2F;leanpub.com&#x2F;productiongo&#x2F;print) but you&#x27;ll need to purchase an ISBN separately (if you want).</code></pre>
acvny大约 4 年前
The author forgot to mention that Amazon kindle publishing take 70% out of your sale price :) Also, that when they print the books, the quality sucks - thick cheap printer paper, toner saver enabled. As a customer I have had very bad experience with books printed by Amazon.
评论 #27132813 未加载
prtkgpt大约 4 年前
It must be hella hard lol!
justaguy88大约 4 年前
If book &lt; 100 pages, I&#x27;m more likely to read it.<p>Can only recommend it to others after reading.