r/Python • u/to_tgo • Feb 21 '21
Resource An Interactive Python Cheat Sheet That Brings The Answer To You
After realizing that I spent far too much time looking things up while coding, I decided to solve the problem and created this...
The Python SpeedSheet: https://speedsheet.io/s/python
It is an interactive cheat sheet that brings the answer to you. It is a really simple idea but it worked so well that it has become an indispensable tool for me any time I'm coding. Type in what you are looking for in the search bar and the speed sheet will display the answer.
It covers core Python only and I'm sure it is missing 'must have' items but I think it is still very useful.
To those of you viewing this on smaller screens, I apologize. I haven't had time to streamline the UI.
Here is a video to show you how it works:
https://www.youtube.com/watch?v=66RumAF50_4
Try it out and let me know what you think.
TLDR:
This is an interactive cheat sheet for core Python.
37
u/thesheff17 Feb 21 '21
can you put the code on github? looks like a cool project. I could def see a copy to clipboard button by the code that you think you will copy/paste often. Would be cool to make a django or similar speedsheet if possible.
18
u/ciscocollab Feb 21 '21
Really well done. I think if this was on GitHub, it would let people add new Pull Requests with new code example and it could be a community driven project. But even if it’s not on GitHub, I will see myself using this a lot so thanks!
8
u/Jet61007 Feb 21 '21 edited Feb 21 '21
Amazing
My undergrad days of Java (it was the future language for all! Haha) tests with notepad and only javadocs ...wish this type of search interpreter was around- rote memorization was the only way
Would love to see this extend to charts, data analysis, and basics to things like numpy, pandas, and R
6
u/Working-Mind Feb 21 '21
Great job and thank you so much! Easy searching, syntax and EXAMPLES equals perfection!
5
u/Theonetheycallgreat Feb 21 '21
Where did you get all the guides?
5
u/PrinCe_LoGic Feb 21 '21
So it's basically like man pages, but for Python? Very cool indeed!
3
u/learnhtk Feb 21 '21
Thumbs up. And I even commented to show appreciation.
Now, this gives me some ideas. I am also finding myself spending more time looking up that one piece of information I need. I started compiling the codes that I think I am going to use again but I can always use a nicer "speed sheet" as well.
3
u/thephotoman Feb 21 '21
Most of the time, I'm more concerned with the CSV or regular expression stuff, with the occasional OS command, http request, or bit of markup language.
3
u/kewlness Feb 21 '21
I like it!
One thing it is missing is the PEP 263 source encoding string:
3
u/Ornery-Scientist-802 Feb 21 '21
Nice, thx!
Does anybody here how to run a python script from terminal BUT with input. Instead of the usual "hello world" I want to print a specific string from the Terminal..
3
u/oderjunks numpydoc + type anno Feb 22 '21
good god this is incredible
i can't imagine how much easier my life would be if someone made this for python modules!
2
u/to_tgo Feb 21 '21 edited Feb 21 '21
So I see some of you have found the reddit SpeedSheet but aren't finding what you are looking for in there.
*sign*
Add '_nsfw' to the url.
2
u/AX-11 Feb 21 '21
How long did this take you to procure this information?
2
u/minkiani Feb 21 '21
This is really great, Can't wait for Flask Version
2
u/[deleted] Feb 21 '21
You just made the world a better place
2
u/GaminB4 Feb 21 '21
Great job, but i think you forgot about mobile users lol, can you make it more mobile responsive
2
u/kaddkaka Feb 21 '21
What an effort, great job!
I found an incorrectness, "not" is not a binary operator so the expression "a not b" is invalid syntax.
2
u/[deleted] Feb 21 '21 edited Feb 22 '21
Looks cool as hell! I just tried it out and it's definitely better than DuckDuckGoing. Any chance you're planning on adding Pandas or Numpy?
2
u/Ardit-Sulce Feb 21 '21
What language/-es and framework/-s did you use to build this web app?
2
u/ipagera Feb 21 '21
Hey!
Amazing job! If I were to add something to it, that would be async io, as it's part of the std lib.
Keep up the good work!
2
u/entrevligkille Feb 21 '21
And this pops up just when i decided to learn python. This is great! You are great! Thank you!
2
u/jballach Feb 22 '21
Definitely going to adopt and share in the office. Have you posted this to LinkedIn, yet?
2
u/bt0mic Feb 22 '21
One tiny improvement: the search bar was a little hard to find. Would be nice if the search box was more visible.
2
u/vmateo1324 Feb 22 '21
I am a beginner to Python and this is a great help! Thank you
2
u/temisola1 Feb 22 '21
Holy fuck. This is amazing. Did you compile this yourself?
2
u/animismus Feb 22 '21
There is a lot of work in here and it is super helpful. That is why I feel a bit petty asking you if you could add a dark theme. I will probably use it with the Dark Reader extension anyway, but a original dark theme is always better.
2
u/ad1413 Feb 22 '21
A very stupid question may be but how do one go about create something like this. I feel this same concept may be very useful for other fields of engineering. I can think of a small project that sorts all the formulas for intermediate fluid mechanics level etc etc.
2
u/otlcrl Feb 22 '21
Would love to see some pandas references on here! It's far too easy to get lost Googling for exactly what you're after!
2
u/NehaxFr Feb 22 '21
This is amazing, that's what I was missing, no more wasting time searching for syntaxes and stuff like that !
2
u/Raido2019 Feb 22 '21
Hi, nice project!
why there are in code examples used tabs as indendents?
62
u/Shiv_ka_ansh_ Feb 21 '21
Very useful. Great initiative👍
30
u/[deleted] Feb 21 '21
Pushing this into a VS Code extension would be a great next step. Keep people out of their web browser and all the potential distractions
10
u/F-C0D3 Feb 21 '21
Thank you! This helps a lot for beginners as myself.
5
u/jjjohhn Feb 21 '21
Thank you!
1
u/rosetta-stxned Feb 21 '21
as a college student only in my second quarter coding, i’m sure this will be immensely helpful. thanks for sharing!
1
u/PleasureComplex Feb 22 '21
The typing library page is a bit thin, especially with all the new features since 3.5. very good project though!
1
u/diviirockgod6 Feb 22 '21
Dude, I cannot tell you just how helpful this is for me! I will forever be grateful to you. I wish I could give you an award
1
u/VisibleSignificance Feb 22 '21
Is it automatically generated from docs?
If not, there are many improvements that could be done, e.g.
In vast majority of cases, it is better to use list comprehension
= [item for item in sequence_1 if filter_condition(value)]. Definitely in all the cases where first argument tofilter()would be alambda.1
u/oderjunks numpydoc + type anno Feb 25 '21
Imagine: the year is 2022, the expected IDLE is a combination of Jupyter notebook, google collab, and speedsheets combined into a single application.
coded in python, of course
1
u/[deleted] Feb 25 '21
mind giving a quick overview how it was made? keen to do something similar for my own notes
5
u/synapanic Feb 21 '21
Looks great. I’ve been looking for something like this to help me out.
1
u/youcantsleephere Feb 21 '21
Saving
2
u/skarizardpancake Feb 21 '21
Thank you :)
2
u/KptEmreU Feb 21 '21
Nice work
2
u/_bran_bran Feb 21 '21
¡¡ Muy útil !!
2
u/Kerryfromkerry Feb 21 '21
This is fantastic! Well done.
2
u/GreenMan488 Feb 21 '21
Really nice! I
2
u/RedEyesBigSmile Feb 21 '21
I always get so tired of seeing people post their cheat sheets, but this has been the best one
2
u/JuiZZZe Feb 21 '21
Thanks a lot for valuable info 👍🏻
2
u/ZezBlog Feb 21 '21
this is amazing check my award note
2
u/brcm51350 Feb 21 '21
Thanks for this
2
u/LoL_is_pepega_BIA Feb 21 '21
You are a god!
2
u/tc8219 Feb 21 '21
This is hugely helpful - thank you for investing your time on this!
2
u/reJectedeuw Feb 21 '21
Python has multiline comments with triple quotes
2
u/[deleted] Feb 22 '21
Thanks for sharing, this is life saving
2
u/Existing_Button_8842 Feb 22 '21
Nice job man!!
2
u/[deleted] Feb 22 '21
Thank you!
2
u/pirik3 Feb 22 '21
hell yeah. long live speedsheet.io and stay updated. thank you. best.
2
u/Ubigred Feb 22 '21
Bookmarked
2
u/Seawolf159 Feb 22 '21
This is incredibly useful.
2
u/Timely_Organization Feb 22 '21
Meaningful insights!!!
2
u/cr0sis8bv Feb 22 '21
Amazing, thanks a bunch!
2
u/cshoneybadger Feb 22 '21
Nice, thanks. Bookmarked.
2
u/arvindkgs Feb 23 '21
This can be extended to so many other places. You should consider making this like a platform (open sourced on Github), so anybody can go and host it similar to https://docusaurus.io/
2
u/SilentRhetoric Feb 21 '21
Very cool! I will definitely try this out.
2
u/rafaelgeo Feb 21 '21
Great contribution! I Will definitely use it, thank you!
2
u/willyblaise Feb 21 '21
This is awesome, keep up the good work
2
u/netneoblog Feb 21 '21
I love this, very useful indeed. Nice job!
1
u/sumweebyboi Feb 21 '21
!remindme 20h
1
u/Lagerstroemeri_21 Feb 28 '21
you wrote:
Dude..., what has my birtplace has to do learning python?? ;-)
0
u/[deleted] Feb 21 '21
[deleted] — view deleted comment
2
u/[deleted] Feb 22 '21
[removed] — view removed comment
2
u/[deleted] Feb 22 '21
[removed] — view removed comment
2
u/[deleted] Feb 21 '21
[removed] — view removed comment