Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Hello, world!
pastebin.com and gist.github.com make it easy to share large amounts of text with people over the web.
@emreerokyar

This comment has been minimized.

Copy link

@emreerokyar emreerokyar commented May 6, 2015

It works!

@max320

This comment has been minimized.

Copy link

@max320 max320 commented Jun 26, 2015

Sweet!

@milesmeow

This comment has been minimized.

Copy link

@milesmeow milesmeow commented Sep 30, 2015

Woohoo. Do people put error code as a gist and discuss it? It feels like gists should all be good snippets of code that people can use.

@MontyPython31

This comment has been minimized.

Copy link

@MontyPython31 MontyPython31 commented Aug 11, 2016

Nice!

@jimcoyle

This comment has been minimized.

Copy link

@jimcoyle jimcoyle commented Nov 7, 2016

so it does

@dmpfr

This comment has been minimized.

Copy link

@dmpfr dmpfr commented Nov 26, 2016

yeay! I love gist!

@drewdle

This comment has been minimized.

Copy link

@drewdle drewdle commented Feb 10, 2017

ere i am jh

@Robicus

This comment has been minimized.

Copy link

@Robicus Robicus commented Feb 21, 2017

It's still here!

@GitCMDR

This comment has been minimized.

Copy link

@GitCMDR GitCMDR commented Apr 22, 2017

Nice book!

@python00078

This comment has been minimized.

Copy link

@python00078 python00078 commented Apr 25, 2017

noice.

@Drewgo2

This comment has been minimized.

Copy link

@Drewgo2 Drewgo2 commented May 5, 2017

Thank you, good book

@ardisplay

This comment has been minimized.

Copy link

@ardisplay ardisplay commented May 31, 2017

Thank you for all the efforts

@LreeLenn

This comment has been minimized.

Copy link

@LreeLenn LreeLenn commented Jun 7, 2017

Cool!

@shivpatil

This comment has been minimized.

Copy link

@shivpatil shivpatil commented Jun 17, 2017

whats this

@KUNAL1612

This comment has been minimized.

Copy link

@KUNAL1612 KUNAL1612 commented Jul 25, 2017

Woohoo!

@GavinHsueh

This comment has been minimized.

Copy link

@GavinHsueh GavinHsueh commented Aug 14, 2017

gook luck

@tomokirin

This comment has been minimized.

Copy link

@tomokirin tomokirin commented Oct 3, 2017

Every day is still day one!!

@dariogabriel113

This comment has been minimized.

Copy link

@dariogabriel113 dariogabriel113 commented Nov 11, 2017

Nice book

@StrawberryUnicorn

This comment has been minimized.

Copy link

@StrawberryUnicorn StrawberryUnicorn commented Dec 15, 2017

late to the party! lol

@Phenol51

This comment has been minimized.

Copy link

@Phenol51 Phenol51 commented Jan 11, 2018

I like the book!

@JfuggyFugg

This comment has been minimized.

Copy link

@JfuggyFugg JfuggyFugg commented Jan 16, 2018

Just started the book. Glad this is still here

@hemrok0101

This comment has been minimized.

Copy link

@hemrok0101 hemrok0101 commented Jan 17, 2018

Awesome!

@ghost

This comment has been minimized.

Copy link

@ghost ghost commented Feb 16, 2018

Still here. 2018

@ivan-yosifov

This comment has been minimized.

Copy link

@ivan-yosifov ivan-yosifov commented Feb 19, 2018

Thank you!

@RajS1991

This comment has been minimized.

Copy link

@RajS1991 RajS1991 commented Feb 22, 2018

Awesome.

@cronnoss

This comment has been minimized.

Copy link

@cronnoss cronnoss commented Mar 4, 2018

ok

@hunter-hub

This comment has been minimized.

Copy link

@hunter-hub hunter-hub commented Mar 8, 2018

Cool.

@styler2004

This comment has been minimized.

Copy link

@styler2004 styler2004 commented Mar 16, 2018

did it.

@stevethomasgb

This comment has been minimized.

Copy link

@stevethomasgb stevethomasgb commented Mar 21, 2018

Great intro, thanks!

@dennohpeter

This comment has been minimized.

Copy link

@dennohpeter dennohpeter commented Mar 26, 2018

just started reading the book

@viviraghav874

This comment has been minimized.

Copy link

@viviraghav874 viviraghav874 commented Apr 2, 2018

bingo !!!

@Tockyto

This comment has been minimized.

Copy link

@Tockyto Tockyto commented Apr 7, 2018

Nice 👍

@SamRicha

This comment has been minimized.

Copy link

@SamRicha SamRicha commented Apr 11, 2018

Just started the book today

@JohnnyCincoCero

This comment has been minimized.

Copy link

@JohnnyCincoCero JohnnyCincoCero commented Apr 17, 2018

Do chickens have large talons?

@anoora17

This comment has been minimized.

Copy link

@anoora17 anoora17 commented Apr 23, 2018

just started reading the book, Sweet

@g4m3rm1k3

This comment has been minimized.

Copy link

@g4m3rm1k3 g4m3rm1k3 commented May 20, 2018

I just picked up your book. sofar so good Pastebin no longer works though

@nicktheo59

This comment has been minimized.

Copy link

@nicktheo59 nicktheo59 commented Jun 6, 2018

Hello all from Evesham in England.
What a time to be alive.

@daron4ever

This comment has been minimized.

Copy link

@daron4ever daron4ever commented Jun 6, 2018

I like your book. Thanks

@codingandcodingandcoding

This comment has been minimized.

Copy link

@codingandcodingandcoding codingandcodingandcoding commented Jun 14, 2018

Your book is baller.

@moalisiddiqui

This comment has been minimized.

Copy link

@moalisiddiqui moalisiddiqui commented Jun 26, 2018

Thank you for the effort you and your team put into "Automate the Boring Stuff With Python"! I ordered the book and I'm enjoying it as my first foray into programming and coding.

For everyone reading this: You can do it! Persistence and Grit!

June 26th, 2018

@HouNaoshao

This comment has been minimized.

Copy link

@HouNaoshao HouNaoshao commented Jun 27, 2018

Nice book!
I love Python!

@imbyron

This comment has been minimized.

Copy link

@imbyron imbyron commented Jun 30, 2018

不错。

@Searge

This comment has been minimized.

Copy link

@Searge Searge commented Jul 9, 2018

Дякую! 😉

@Guvargam

This comment has been minimized.

Copy link

@Guvargam Guvargam commented Jul 10, 2018

Thanks a lot for touching my life to make me better person. i know coding now and i have i job on this era. In future we came to america for living. Yes, that was the life changing book.
Thanks again

@lixiang2017

This comment has been minimized.

Copy link

@lixiang2017 lixiang2017 commented Aug 5, 2018

It's still here! 2018

@Siri94

This comment has been minimized.

Copy link

@Siri94 Siri94 commented Aug 6, 2018

Who is reading his book, everybody visits here.

@skygreen2001

This comment has been minimized.

Copy link

@skygreen2001 skygreen2001 commented Aug 14, 2018

excellent

@nicholasbyres

This comment has been minimized.

Copy link

@nicholasbyres nicholasbyres commented Aug 15, 2018

Why not leave a comment...

@OyeBenny

This comment has been minimized.

Copy link

@OyeBenny OyeBenny commented Aug 24, 2018

Wanted to be a part of this.

@googkhan

This comment has been minimized.

Copy link

@googkhan googkhan commented Aug 29, 2018

Thanks for beatiful book!

@fastlanecabbie

This comment has been minimized.

Copy link

@fastlanecabbie fastlanecabbie commented Sep 2, 2018

Thanks for the python book!

@rossizou

This comment has been minimized.

Copy link

@rossizou rossizou commented Sep 11, 2018

nice book, just start today, hope i can learn python good!

@Sheafy

This comment has been minimized.

Copy link

@Sheafy Sheafy commented Sep 19, 2018

Part 1.....

@Lucas-101

This comment has been minimized.

Copy link

@Lucas-101 Lucas-101 commented Sep 28, 2018

Nice book

@rcd00

This comment has been minimized.

Copy link

@rcd00 rcd00 commented Oct 19, 2018

woahh

@silver8177

This comment has been minimized.

Copy link

@silver8177 silver8177 commented Oct 23, 2018

hello world, just start today

@LivCodes

This comment has been minimized.

Copy link

@LivCodes LivCodes commented Nov 9, 2018

ayyyeeee both links work

@5h4rp

This comment has been minimized.

Copy link

@5h4rp 5h4rp commented Nov 13, 2018

Hello World! XD

@Chootana

This comment has been minimized.

Copy link

@Chootana Chootana commented Nov 14, 2018

start today

@ddeets

This comment has been minimized.

Copy link

@ddeets ddeets commented Nov 19, 2018

Fantastic!

@yeah2u

This comment has been minimized.

Copy link

@yeah2u yeah2u commented Nov 21, 2018

Thanks!
Wish i could follow u.

@ElianBelot

This comment has been minimized.

Copy link

@ElianBelot ElianBelot commented Nov 24, 2018

Nice book so far!

@ger228

This comment has been minimized.

Copy link

@ger228 ger228 commented Dec 10, 2018

добрый день

@trystankk

This comment has been minimized.

Copy link

@trystankk trystankk commented Dec 12, 2018

Awsome

@dvnckr

This comment has been minimized.

Copy link

@dvnckr dvnckr commented Dec 29, 2018

cool

@ccmorataya

This comment has been minimized.

Copy link

@ccmorataya ccmorataya commented Jan 8, 2019

👍

@maestro180220

This comment has been minimized.

Copy link

@maestro180220 maestro180220 commented Jan 17, 2019

Just stared reading the book today, cool book! Thank you!

@BrianFenn

This comment has been minimized.

Copy link

@BrianFenn BrianFenn commented Jan 24, 2019

just beginning my python course for class. Hello Class!

@kelvinkit

This comment has been minimized.

Copy link

@kelvinkit kelvinkit commented Jan 28, 2019

Hi all, I am beginner, just start reading this book, seems a great book to learn!! 2019/1/28

@msilverglate

This comment has been minimized.

Copy link

@msilverglate msilverglate commented Feb 6, 2019

Looking forward to making programs to handle my data

@rjmead

This comment has been minimized.

Copy link

@rjmead rjmead commented Feb 19, 2019

👍 😄

@sandroku63

This comment has been minimized.

Copy link

@sandroku63 sandroku63 commented Feb 27, 2019

Cool~

@skhot11

This comment has been minimized.

Copy link

@skhot11 skhot11 commented Mar 29, 2019

new journey.

@aashgaurav

This comment has been minimized.

Copy link

@aashgaurav aashgaurav commented Apr 1, 2019

and hence it begins..

@dudeOnGitHub

This comment has been minimized.

Copy link

@dudeOnGitHub dudeOnGitHub commented Apr 2, 2019

This is like visiting a famous place.

@gauravrock

This comment has been minimized.

Copy link

@gauravrock gauravrock commented Apr 6, 2019

one of the best book!!

@gauravrock

This comment has been minimized.

Copy link

@gauravrock gauravrock commented Apr 6, 2019

one of the best book!!

@Ruslan1411

This comment has been minimized.

Copy link

@Ruslan1411 Ruslan1411 commented Apr 12, 2019

My first step with python.

@armontej

This comment has been minimized.

Copy link

@armontej armontej commented Apr 18, 2019

yee yee

@jaydarius

This comment has been minimized.

Copy link

@jaydarius jaydarius commented Apr 23, 2019

Howdy it's 2019

@seheaven

This comment has been minimized.

Copy link

@seheaven seheaven commented Apr 24, 2019

And here we are almost 6 years later.

@iproman

This comment has been minimized.

Copy link

@iproman iproman commented May 3, 2019

Hey hey hey) What's up? Thanks for the book!!! Don't stop learning!!!!!

@Kpopslayer

This comment has been minimized.

Copy link

@Kpopslayer Kpopslayer commented May 9, 2019

Thank you for your great work! :)

@SifisoPatel

This comment has been minimized.

Copy link

@SifisoPatel SifisoPatel commented May 13, 2019

Hello World

@TechExhibeo

This comment has been minimized.

Copy link

@TechExhibeo TechExhibeo commented Jun 6, 2019

Gist Still Alive <3

@a-umair

This comment has been minimized.

Copy link

@a-umair a-umair commented Jun 12, 2019

Learning a ton from your book, Al!

@rizki113070213

This comment has been minimized.

Copy link

@rizki113070213 rizki113070213 commented Jun 23, 2019

Hi all, just start reading this book, seems a great book to learn!!

@gv-git

This comment has been minimized.

Copy link

@gv-git gv-git commented Jul 13, 2019

Hello, Another reader.

@gaddielespinosa

This comment has been minimized.

Copy link

@gaddielespinosa gaddielespinosa commented Jul 13, 2019

It still working!

@Filivanili

This comment has been minimized.

Copy link

@Filivanili Filivanili commented Jul 24, 2019

Can confirm, just got the book after reading about it for years on reddit. Better late than never!

@Feracitus

This comment has been minimized.

Copy link

@Feracitus Feracitus commented Jul 25, 2019

yohoho! lets get this done!

@CrazyWangSir

This comment has been minimized.

Copy link

@CrazyWangSir CrazyWangSir commented Aug 16, 2019

hellow world! im Chinese~

@IaroslavTavchenkov

This comment has been minimized.

Copy link

@IaroslavTavchenkov IaroslavTavchenkov commented Aug 16, 2019

It works! Your book is awesome! 😃

@IaroslavTavchenkov

This comment has been minimized.

Copy link

@IaroslavTavchenkov IaroslavTavchenkov commented Aug 16, 2019

hellow world! im Chinese~

你好!
你的国家很棒!

@MohammedJouhar

This comment has been minimized.

Copy link

@MohammedJouhar MohammedJouhar commented Sep 7, 2019

I am starting to use GIT hub from now

@Aaronmx1

This comment has been minimized.

Copy link

@Aaronmx1 Aaronmx1 commented Sep 14, 2019

Started your book this morning!

@MohammedJouhar

This comment has been minimized.

Copy link

@MohammedJouhar MohammedJouhar commented Sep 15, 2019

Page number 65 now 😬

@migueldb

This comment has been minimized.

Copy link

@migueldb migueldb commented Sep 26, 2019

Great book. It looks like pastebin.com is down....

@Genadeb

This comment has been minimized.

Copy link

@Genadeb Genadeb commented Oct 9, 2019

Looks like I'm doing this now. Good luck everyone!

@MasterMynk

This comment has been minimized.

Copy link

@MasterMynk MasterMynk commented Nov 7, 2019

Straight from the book. (Your pastebin link does not work)

This comment was marked as spam.

Copy link

@guruskid guruskid commented Nov 14, 2019

I am building a project but am looking for a full-stack dev that will join me on the project, if anyone is interested should contact me on configureall@gmail.com with the title PROJECT

@badumtsch

This comment has been minimized.

Copy link

@badumtsch badumtsch commented Nov 16, 2019

This is awesome. Thank you for writing this book!

@sunset904

This comment has been minimized.

Copy link

@sunset904 sunset904 commented Nov 24, 2019

😁

@odus13

This comment has been minimized.

Copy link

@odus13 odus13 commented Dec 10, 2019

Started. December 2019

@scottie

This comment has been minimized.

Copy link

@scottie scottie commented Dec 11, 2019

are you taking the piss ?

@elohimgv

This comment has been minimized.

Copy link

@elohimgv elohimgv commented Dec 27, 2019

Wow! I like this.

@rroblsgo

This comment has been minimized.

Copy link

@rroblsgo rroblsgo commented Dec 30, 2019

amazing!!

@joshjavier

This comment has been minimized.

Copy link

@joshjavier joshjavier commented Jan 17, 2020

Starting 2020 by learning how to code with Python. Wassup! 👋

@VLKanz

This comment has been minimized.

Copy link

@VLKanz VLKanz commented Jan 19, 2020

Starting 2020 while learning python, nice!

@jbasallaje

This comment has been minimized.

Copy link

@jbasallaje jbasallaje commented Jan 23, 2020

2020 Gang What up! This book sure has legs..

@ericance

This comment has been minimized.

Copy link

@ericance ericance commented Feb 8, 2020

hi

@bingohu2019github

This comment has been minimized.

Copy link

@bingohu2019github bingohu2019github commented Feb 17, 2020

Leave a mark 🀄️

@mikabakajic

This comment has been minimized.

Copy link

@mikabakajic mikabakajic commented Feb 17, 2020

I am posting from the future

@vinilaa

This comment has been minimized.

Copy link

@vinilaa vinilaa commented Feb 22, 2020

Thanks man. You are the best!!!

@Mohmd-Ali

This comment has been minimized.

Copy link

@Mohmd-Ali Mohmd-Ali commented Feb 25, 2020

Very informative and beginner-friendly book, thanks to Al Sweigart. :)

@Vuemiester

This comment has been minimized.

Copy link

@Vuemiester Vuemiester commented Feb 26, 2020

Thus begins the coding journey.

@aruljothi07

This comment has been minimized.

Copy link

@aruljothi07 aruljothi07 commented Feb 26, 2020

'34' + 2
Traceback (most recent call last):
File "", line 1, in
TypeError: must be str, not int

Give error explaination...

@Mohmd-Ali

This comment has been minimized.

Copy link

@Mohmd-Ali Mohmd-Ali commented Feb 26, 2020

'34' + 2
Traceback (most recent call last):
File "", line 1, in
TypeError: must be str, not int

Give error explaination...

'34' is of type String whereas 2 is of type Integer. So concatenation is not allowed when there is a datatype mismatch between two values. For that purpose, you need to write 2 in single quotes like this '2' which means you're declaring it as String so the result will be '342'. On the other side if you don't write 2 in single quotes and remove the single quotes from '34' instead then it will apply mathematical operation of addition on both values and the result will become 36. Here is an easy explanation for you.

@dexterpound

This comment has been minimized.

Copy link

@dexterpound dexterpound commented Feb 26, 2020

Nice it works like a charm on hooch

@amartadey

This comment has been minimized.

Copy link

@amartadey amartadey commented Mar 10, 2020

### Loving the book

@mouselabsio

This comment has been minimized.

Copy link

@mouselabsio mouselabsio commented Mar 25, 2020

OH JESS.

@sohamsurya311

This comment has been minimized.

Copy link

@sohamsurya311 sohamsurya311 commented Apr 4, 2020

ohh yey it work this book is awesome

@sohamsurya311

This comment has been minimized.

Copy link

@sohamsurya311 sohamsurya311 commented Apr 4, 2020

num=int(input("enter any integer number"))
for i in range(num,2):
if num % i!=0:
print("no is prime")
break
else:
print("not prime")

#hello everyone can you help out ,cause i am not able find this logical error cause whenever i compile always the output is "not prime"

@ifeLawal

This comment has been minimized.

Copy link

@ifeLawal ifeLawal commented Apr 5, 2020

as a note @s

num=int(input("enter any integer number"))
for i in range(num,2):
if num % i!=0:
print("no is prime")
break
else:
print("not prime")

#hello everyone can you help out ,cause i am not able find this logical error cause whenever i compile always the output is "not prime"

  1. range(a, b) does not go up to b. so for i in range(1, 2) i only equals 1, it doesn't go up to 2.
  2. since you have num as input
    and for i in range(num, 2) your first i will always be equal to num.
    so your first if will always look like
    num % num != 0:
    which will always be false.
    ie if your input is 0.
    num = 0
    your first i = 0
    0 % 0 = 0 so you get "not prime"
    then 0 % 1 is also 0
  3. if your num is greater than 2, the loop will not run.

With those 3 things in effect, your logic will always return "not prime." If you want to help yourself see how this is working you can print your num and i in the code to see what is being tested.

This would be the sample code:

num = int(input("enter any integer number"))
for i in range(num,2):
print('num: ' + str(num)+', i: ' +str(i))
if num % i!=0:
print("no is prime")
break
else:
print("not prime")

@rxlifter

This comment has been minimized.

Copy link

@rxlifter rxlifter commented Apr 7, 2020

Hello Github! Enjoying the book :)

@Samrat-GC

This comment has been minimized.

Copy link

@Samrat-GC Samrat-GC commented Apr 22, 2020

hooopaaah

@CalcCrunch

This comment has been minimized.

Copy link

@CalcCrunch CalcCrunch commented Apr 23, 2020

Chapter 0 completed! :D

@lnaq

This comment has been minimized.

Copy link

@lnaq lnaq commented May 12, 2020

Thank you for your effort !!

@vimalav

This comment has been minimized.

Copy link

@vimalav vimalav commented May 15, 2020

:) Thanks for the Book

@josielguedes

This comment has been minimized.

Copy link

@josielguedes josielguedes commented May 19, 2020

Hello, Phyton!

@Danthesage01

This comment has been minimized.

Copy link

@Danthesage01 Danthesage01 commented May 31, 2020

Thanks for the book. It's a good read.

@bluedove19

This comment has been minimized.

Copy link

@bluedove19 bluedove19 commented Jun 22, 2020

Just started your book and loving it so far. I don't think much has changed as the book was written few years back?

@Justsomeuser

This comment has been minimized.

Copy link

@Justsomeuser Justsomeuser commented Jun 22, 2020

Late to the party but let's get going!!

@RSalu

This comment has been minimized.

Copy link

@RSalu RSalu commented Jul 7, 2020

Hi, Great Book, easy to learn

@figure4

This comment has been minimized.

Copy link

@figure4 figure4 commented Jul 15, 2020

It looks like that ^^^ guy, Fred, just automated the boring stuff 5 times...

@Fred-Reis

This comment has been minimized.

Copy link

@Fred-Reis Fred-Reis commented Jul 15, 2020

It looks like that ^^^ guy, Fred, just automated the boring stuff 5 times...

Sorry man, it was a test of an application. I already deleted the comments

@MaximusaurusRex

This comment has been minimized.

Copy link

@MaximusaurusRex MaximusaurusRex commented Jul 27, 2020

Hello, world and hello, Python!

@Gaalmega

This comment has been minimized.

Copy link

@Gaalmega Gaalmega commented Jul 29, 2020

nice!

@meesh924

This comment has been minimized.

Copy link

@meesh924 meesh924 commented Aug 5, 2020

Hiyeee

@CrazyWangSir

This comment has been minimized.

Copy link

@CrazyWangSir CrazyWangSir commented Aug 5, 2020

@wecae

This comment has been minimized.

Copy link

@wecae wecae commented Aug 6, 2020

Hello, asweigart~!
I continue to study this amazing python book !
very interesting

I will be good web programmer in the near future.
and I will construct brand web site of mine about engineering technology!
Thanks!
See you again
SEEYA

@programmingfinally

This comment has been minimized.

Copy link

@programmingfinally programmingfinally commented Aug 9, 2020

I am finally here :)

@gitdxb

This comment has been minimized.

Copy link

@gitdxb gitdxb commented Aug 24, 2020

Thanks for the nice book!

@gregg00

This comment has been minimized.

Copy link

@gregg00 gregg00 commented Sep 8, 2020

嗨,您好

@eheieh

This comment has been minimized.

Copy link

@eheieh eheieh commented Sep 27, 2020

nice book

@acostaleo

This comment has been minimized.

Copy link

@acostaleo acostaleo commented Oct 2, 2020

Just got your book! the adventure begins...

@lalallal4ik

This comment has been minimized.

Copy link

@lalallal4ik lalallal4ik commented Oct 14, 2020

Hello everybody! And hello, Python!

@Anopta

This comment has been minimized.

Copy link

@Anopta Anopta commented Oct 26, 2020

Lets get started. This is already fun....hahaha

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.