Hacker News new | past | comments | ask | show | jobs | submit login
Ask HN: Learn Python coming from C# background
8 points by humanlion87 13 days ago | hide | past | favorite | 11 comments
I have been coding in C#/.NET for the past few years. Am interested in dabbling in some AI/ML, especially applications related to healthcare and biology. Based on some quick research, it seems like I need to get familiar with Python before I dive into the actual ML stuff. I have never used Python before. There are innumerable resources on the web for learning Python and I am finding it hard to figure out which might be best. So I thought I would turn to the experienced HN crowd to get some feedback :). Any suggestions on material for the best way to get familiar with Python for a C# developer?

Thanks






I know this doesn't answer your question directly, but depending on how much time you intend to spend dabbling in AI/ML, it might not be worth it to first learn a whole new programming environment.

So, you might be able to dabble enough while staying productive with C#. Take a look at ML.NET: https://docs.microsoft.com/en-us/dotnet/machine-learning/

Edit: And everything you learn from that experience will still be useful if you decide later on to dive deeper with Python.


Thanks for the suggestion. I actually never considered this angle! I'll definitely take a look at ML.NET and see whether that will suit my current needs.

also consider F# + ML.NET

I would recommend two books from No Starch Press:

1. Python Crash Course https://nostarch.com/pythoncrashcourse2e

2. Automate the Boring Stuff with Python https://nostarch.com/automatestuff2

The first book will help you to understand the basic concept of programming with Python. It also contains some projects that you can follow in the last chapters. The second book is about automating stuff that are done manually. Let's say, you usually do something over and over again. You can try to automate them using Python. The key of learning programming is practice. If you are curious about other book, you can check https://nostarch.com/catalog/python.

I heard good stuff about Learn Python The Hard Way. But, I've never tried the course. It's a paid course. You can take a look on https://learnpythonthehardway.org/python3/.


I don't know about C#/.NET but I assume you are comfortable with general programming concepts. There are several guides that can help you to quickly familiarize with Python syntax. [0] [1]

For Python eco-system related concepts like virtual environment, testing, and other modules, [2] is good.

I don't have any experience with AI/ML, [3] might help if you are looking for books.

[0] https://docs.python.org/3/tutorial/

[1] https://github.com/jakevdp/WhirlwindTourOfPython

[2] https://calmcode.io/

[3] https://pythonbooks.org/topical-books/machine-learning-and-a...


I second the recommnedation for Whirlwind Tour of Python for people who already know other programming languages and don't need to learn programming concepts from scratch.

As someone who did this years ago, python is really easy to learn once you know C# well.

The only complication is learning command line bullshit and basically copypasta of hopefully benign incomprehensible commands rather than clear UIs, which has been creeping into .Net anyway.


I like this book: http://openbookproject.net/thinkcs/python/english3e/ – it’s not so garrulous. Good for quickly looking up concepts.

Also check out the various community resources. The #python channel on Freenode is good. On Reddit there is https://www.reddit.com/r/learnpython/


The guys over at Talk Python has a dedicated course that sounds like what you need: https://training.talkpython.fm/courses/explore_dotnet/python...

I can't comment on the quality of the course as I haven't taken it, but generally speaking Talk Python usually has high quality stuff.

Hope this helps!


These are some of the lab exercises that I give to my students to get them up to speed with Python on my Distributed Systems course: https://github.com/joaoventura/full-speed-python

They are 2nd year students which are mostly fluent in Java..


> best way to get familiar with Python for a C# developer?

Diving directly into the code.

Writing Python is very close to writing pseudo code. Google "how to do X" and check the official doc when you need it.




Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact

Search: