Does anyone know a good book to buy for beginners to coding for artificial intelligence?
I have done some coding in Java and a little with Python, but I would be willing to learn a new language too.
Introduction to statistical learning is sort of a resource for the tools that go into AI programming, with some exercises in R.
Elements of statistical learning is the more scientific and math / theory heavy version of ISL. I’m reading that one now.
They are both freely available from Stanford online at the links above.
The Direct Answer to Your Question:--
I recommend: Automate the Boring Stuff with Python: Practical Programming for Total Beginners.
" ... Does anyone know a good book to buy for beginners to coding for artificial intelligence? ... " ~ Stephen Messing (Stack Exchange user)
The key word here is beginners.
A very serious issue with people studying advanced topics is not having a strong base in the beginner topics. A house without structure will collapse. Follow these two principles:  step-by-step and  first things first.
Impatience is a very serious issue for folks starting off in A.I., as people can have expectations that do not match up with the actual field. A.I. is a demanding, intense field requiring intense dedication and study.
A solution to these problems is to supply a very practical and hands-on book that provides direct results upon applying the techniques therein but still reinforces the fundamentals.
So, with all of the above in mind and considered, I recommend Automate the Boring Stuff with Python: Practical Programming for Total Beginners.
If you ask "Does anyone know a good book to buy for beginners to coding for artificial intelligence? " Then by all means you get opinionated answer which might not be supported by facts,due to not being specific.
Under artificial intelligence, try to select or choose your area of interest;For instance,NLP(Natural Language Processing) and this has got some interesting applications like ChatBot development.
Now after choosing your area of focus,check out open source communities like GitHub,basing on statistics of programming language that is widely used to have implement such apps is python and Java bindings.And the good thing about github is that resources like books/tutotials etc.are open source.
Hope this can give you a glimpse.
Have a look at Programming Collective Intelligence (2007) by Toby Segaran. It is mainly about machine learning than conventional AI techniques, such as search algorithms or path planning.
Check this link for some suggestions on famous Deep Learning books. The reason why I'm suggesting you to learn deep learning, is that AI is currently achieved through deep learning. Also there is a huge online courses and support for deep learning rather than for traditional AI. You can look for online courses of Andrew Ng or the likes in Udemy.
My personal favourite book on deep learning is "Deep Learning" by Ian Goodfellow et.al. It begins with discussing the necessary mathematics for deep learning which will be very useful for beginners.
Does it have to be a book? I've found if you can set aside the time, the content in the below courses is a good place to start and you can usually get a coupon from Udemy and they are around $10 USD each.
Good tuition sections followed by coding examples which you can play around with.