I am a bioinformatics student and am in the process of learning perl. I don't have a strong programming background but would like for that to change.
我是一名生物信息学专业的学生,正在学习perl。我没有强大的编程背景,但希望改变。
Right now I am in the process of reading/following and coding from this book
现在我正在阅读本书的阅读/跟踪和编码过程
I want to know is this the best way to go about learning perl? Should I be experimenting with regular expressions more? Should I keep trying writing sample perl scripts?
我想知道这是学习perl的最好方法吗?我应该更多地试验正则表达式吗?我应该继续尝试编写样本perl脚本吗?
Related: what are good books for learning perl
相关:什么是学习perl的好书
9 个解决方案
#1
The definitive learning Perl book is aptly called "Learning Perl". Get it.
最权威的学习Perl书被恰当地称为“学习Perl”。得到它。
I cannot recommend writing sample scripts. Try to write something that you need. It doesn't have to be a big endeavor; everyone needs a little tool now and then. Writing sample scripts is boring; always was, always will be.
我不建议编写示例脚本。尝试写下你需要的东西。它不一定是一项重大努力;每个人都需要一个小工具。编写示例脚本很无聊;永远是,永远都是。
#2
This seems like a potential duplicate as here are some related questions:
这似乎是一个潜在的重复,因为这里有一些相关的问题:
- What are the best resources to starting learning Perl?
- What’s the best online source to learn Perl?
开始学习Perl的最佳资源是什么?
学习Perl的最佳在线资源是什么?
#3
Like most other answers on this post I can't disagree with the choice of "Learning Perl" as your first Perl text. Keep a copy of the perldoc documentation available for quick reference(I prefer using the html/pdf format which is available as a download from the main page).
像这篇文章中的大多数其他答案一样,我不能不同意“学习Perl”作为您的第一个Perl文本的选择。保留perldoc文档的副本以供快速参考(我更喜欢使用html / pdf格式,可从主页下载)。
In order to keep things from getting boring, especially in the initial stages I started converting my shell scripts to Perl, hacking away at it until I had three or more different versions of the same program with decreasing file size(not great for maintenance though). But then you know what they say - TMTOWTDI. Now I don't bother with shell scripts any more, writing it in Perl results in smaller turnaround times and the code can be easily reused and enhanced.
为了避免让事情变得无聊,特别是在初始阶段,我开始将我的shell脚本转换为Perl,一直在破解它,直到我有三个或更多不同版本的同一程序,文件大小减小(虽然不太适合维护) 。但后来你知道他们说了什么 - TMTOWTDI。现在我不再需要使用shell脚本,在Perl中编写它会缩短周转时间,并且可以轻松地重用和增强代码。
Once you are familiar with the more advanced concepts and are approaching a level of comfortability with using it for your day-to-day work or just simple one-liners you might want to have a look at Mark Jason Dominus' Higher-Order Perl which, according to me, takes the language and the reader's understanding of it to an entirely new level. The chapter on "Recursion and Callbacks" was a real eye-opener and changed my style completely from that of writing C-programs in Perl to actually writing "Perl" programs in Perl.
一旦您熟悉了更高级的概念,并将其用于日常工作或仅仅是简单的单行程,即可达到一定的舒适度,您可能需要查看Mark Jason Dominus的高阶Perl。据我所知,将语言和读者对它的理解提升到一个全新的水平。关于“递归和回调”的章节真是令人大开眼界,完全改变了我的风格,从在Perl中编写C程序到在Perl中实际编写“Perl”程序。
#4
I use the online book "Learning Perl the Hard Way" to teach my coworkers about Perl.
我使用在线书“学习Perl the Hard Way”来向我的同事讲授Perl。
Don't be intimidated by the title, it's just that it's directed at programmers who are already fluent in another language and therefore it doesn't focus on the programming part, but mostly on the Perl part, so it may apply better to your case (or not).
不要被标题吓倒,只是它是针对那些已经精通另一种语言的程序员,因此它不专注于编程部分,但主要是在Perl部分,所以它可能更适用于你的情况(或不)。
#5
You really can't go wrong with the Lama book
你真的不会错误的喇嘛书
There's quite a library of O'Reilly books on Perl. Programming Perl is also excellent and probably worth having to complement the Lama book - I have both on my shelves and although I haven't needed to code in Perl for quite some time I found these books together a solid enough combination. The Perl Cookbook came in useful too (yes, this is one of those areas that O'Reilly has pretty much sew up :-).
在Perl上有很多关于O'Reilly图书的图书馆。编程Perl也非常出色,可能值得补充喇嘛书 - 我有两个都在我的书架上,虽然我不需要在Perl中编码很长一段时间我发现这些书在一起足够坚固。 Perl Cookbook也很有用(是的,这是O'Reilly几乎已经解决的领域之一:-)。
As to practical exercises, Perl does have something of a reputation as a 'Write Only' language, so look for clear examples and if you are confused by anything don't necessarily assume that the problem is you - there's always more than one way to do it.
至于实际练习,Perl确实具有“只写”语言的声誉,所以寻找清晰的例子,如果你对任何事情感到困惑,不一定认为问题在于你 - 总有不止一种方法做到这一点。
#7
My experience is that there's nothing better for learning than doing. But you need someone to provide feedback, especially when you hit roadblocks that you can't get past. * is good for that, but, IME, Perlmonks is better in that there is a chatterbox for immediate feedback, as well as their question-and-answer posts for longer questions, combined with a more specialised environment. (And Larry Wall has been rumoured to hang out there, too, as well as a number of the authors of the above-referred-to books.)
我的经验是,学习没有比做更好的了。但是你需要有人提供反馈,特别是当你遇到无法通过的障碍时。 *很有用,但是,IME,Perlmonks更好的是有一个聊天框可以立即反馈,以及他们的问答帖子可以提供更长的问题,并结合更专业的环境。 (据传,拉里·沃尔也在那里,以及上述书籍的一些作者。)
#8
Learn by doing. Get the books mentioned by others, but the real way to learn is to start a simple project. Mine was a Gtk based SQL editor. If you run into problems ask questions here and on the Perl Beginners list.
通过实践学习。获取其他人提到的书籍,但真正的学习方法是开始一个简单的项目。我是一个基于Gtk的SQL编辑器。如果您遇到问题,请在此处和Perl初学者列表中提出问题。
#9
The choice of book is can be vary from person to person. So, as bioinformatics student who use perl, don't get any book that called "(X Programming language) for bioinformatics". Usually this kind of book is either.
书的选择可能因人而异。因此,作为使用perl的生物信息学学生,不要获得任何称为“(X编程语言)生物信息学”的书。通常这种书也是。
- They only give very basic of that programming language. You gonna to miss all the power from that language.
- Wasting its space on how to use API, which you can find information easily via google.
它们只提供了该编程语言的基础知识。你会错过那种语言的所有力量。
浪费了如何使用API的空间,您可以通过谷歌轻松找到信息。
#1
The definitive learning Perl book is aptly called "Learning Perl". Get it.
最权威的学习Perl书被恰当地称为“学习Perl”。得到它。
I cannot recommend writing sample scripts. Try to write something that you need. It doesn't have to be a big endeavor; everyone needs a little tool now and then. Writing sample scripts is boring; always was, always will be.
我不建议编写示例脚本。尝试写下你需要的东西。它不一定是一项重大努力;每个人都需要一个小工具。编写示例脚本很无聊;永远是,永远都是。
#2
This seems like a potential duplicate as here are some related questions:
这似乎是一个潜在的重复,因为这里有一些相关的问题:
- What are the best resources to starting learning Perl?
- What’s the best online source to learn Perl?
开始学习Perl的最佳资源是什么?
学习Perl的最佳在线资源是什么?
#3
Like most other answers on this post I can't disagree with the choice of "Learning Perl" as your first Perl text. Keep a copy of the perldoc documentation available for quick reference(I prefer using the html/pdf format which is available as a download from the main page).
像这篇文章中的大多数其他答案一样,我不能不同意“学习Perl”作为您的第一个Perl文本的选择。保留perldoc文档的副本以供快速参考(我更喜欢使用html / pdf格式,可从主页下载)。
In order to keep things from getting boring, especially in the initial stages I started converting my shell scripts to Perl, hacking away at it until I had three or more different versions of the same program with decreasing file size(not great for maintenance though). But then you know what they say - TMTOWTDI. Now I don't bother with shell scripts any more, writing it in Perl results in smaller turnaround times and the code can be easily reused and enhanced.
为了避免让事情变得无聊,特别是在初始阶段,我开始将我的shell脚本转换为Perl,一直在破解它,直到我有三个或更多不同版本的同一程序,文件大小减小(虽然不太适合维护) 。但后来你知道他们说了什么 - TMTOWTDI。现在我不再需要使用shell脚本,在Perl中编写它会缩短周转时间,并且可以轻松地重用和增强代码。
Once you are familiar with the more advanced concepts and are approaching a level of comfortability with using it for your day-to-day work or just simple one-liners you might want to have a look at Mark Jason Dominus' Higher-Order Perl which, according to me, takes the language and the reader's understanding of it to an entirely new level. The chapter on "Recursion and Callbacks" was a real eye-opener and changed my style completely from that of writing C-programs in Perl to actually writing "Perl" programs in Perl.
一旦您熟悉了更高级的概念,并将其用于日常工作或仅仅是简单的单行程,即可达到一定的舒适度,您可能需要查看Mark Jason Dominus的高阶Perl。据我所知,将语言和读者对它的理解提升到一个全新的水平。关于“递归和回调”的章节真是令人大开眼界,完全改变了我的风格,从在Perl中编写C程序到在Perl中实际编写“Perl”程序。
#4
I use the online book "Learning Perl the Hard Way" to teach my coworkers about Perl.
我使用在线书“学习Perl the Hard Way”来向我的同事讲授Perl。
Don't be intimidated by the title, it's just that it's directed at programmers who are already fluent in another language and therefore it doesn't focus on the programming part, but mostly on the Perl part, so it may apply better to your case (or not).
不要被标题吓倒,只是它是针对那些已经精通另一种语言的程序员,因此它不专注于编程部分,但主要是在Perl部分,所以它可能更适用于你的情况(或不)。
#5
You really can't go wrong with the Lama book
你真的不会错误的喇嘛书
There's quite a library of O'Reilly books on Perl. Programming Perl is also excellent and probably worth having to complement the Lama book - I have both on my shelves and although I haven't needed to code in Perl for quite some time I found these books together a solid enough combination. The Perl Cookbook came in useful too (yes, this is one of those areas that O'Reilly has pretty much sew up :-).
在Perl上有很多关于O'Reilly图书的图书馆。编程Perl也非常出色,可能值得补充喇嘛书 - 我有两个都在我的书架上,虽然我不需要在Perl中编码很长一段时间我发现这些书在一起足够坚固。 Perl Cookbook也很有用(是的,这是O'Reilly几乎已经解决的领域之一:-)。
As to practical exercises, Perl does have something of a reputation as a 'Write Only' language, so look for clear examples and if you are confused by anything don't necessarily assume that the problem is you - there's always more than one way to do it.
至于实际练习,Perl确实具有“只写”语言的声誉,所以寻找清晰的例子,如果你对任何事情感到困惑,不一定认为问题在于你 - 总有不止一种方法做到这一点。
#6
You also might want to look for examples of good code to study.
您也可能希望查找要学习的优秀代码的示例。
#7
My experience is that there's nothing better for learning than doing. But you need someone to provide feedback, especially when you hit roadblocks that you can't get past. * is good for that, but, IME, Perlmonks is better in that there is a chatterbox for immediate feedback, as well as their question-and-answer posts for longer questions, combined with a more specialised environment. (And Larry Wall has been rumoured to hang out there, too, as well as a number of the authors of the above-referred-to books.)
我的经验是,学习没有比做更好的了。但是你需要有人提供反馈,特别是当你遇到无法通过的障碍时。 *很有用,但是,IME,Perlmonks更好的是有一个聊天框可以立即反馈,以及他们的问答帖子可以提供更长的问题,并结合更专业的环境。 (据传,拉里·沃尔也在那里,以及上述书籍的一些作者。)
#8
Learn by doing. Get the books mentioned by others, but the real way to learn is to start a simple project. Mine was a Gtk based SQL editor. If you run into problems ask questions here and on the Perl Beginners list.
通过实践学习。获取其他人提到的书籍,但真正的学习方法是开始一个简单的项目。我是一个基于Gtk的SQL编辑器。如果您遇到问题,请在此处和Perl初学者列表中提出问题。
#9
The choice of book is can be vary from person to person. So, as bioinformatics student who use perl, don't get any book that called "(X Programming language) for bioinformatics". Usually this kind of book is either.
书的选择可能因人而异。因此,作为使用perl的生物信息学学生,不要获得任何称为“(X编程语言)生物信息学”的书。通常这种书也是。
- They only give very basic of that programming language. You gonna to miss all the power from that language.
- Wasting its space on how to use API, which you can find information easily via google.
它们只提供了该编程语言的基础知识。你会错过那种语言的所有力量。
浪费了如何使用API的空间,您可以通过谷歌轻松找到信息。