从 Perl 切换到 Python 的演示 [英] Presentations on switching from Perl to Python

查看:36
本文介绍了从 Perl 切换到 Python 的演示的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

小故事:

我正在寻找有关从 Perl 切换到 Python 的演示文稿/好文章.

I'm looking for presentations/good articles on switching from Perl to Python.

更长的故事:

我是硬件设计小组的一名程序员/嵌入式硬件工程师.几年前,我说服我的同事使用 Perl 编写脚本(而不是批处理文件、Excel、Matlab 和 TCL 的奇怪混合).从那时起,我自己就从 Perl 切换到 Python,并对这种变化感到非常高兴.我想以某种方式说服我的同事遵循我的道路,但我需要好的观点来说服他们.这些不能像更好的反射设施一样是沉重的程序员巫术(与我不同,这里的大多数人都是 EE 毕业生而不是程序员).

I'm a programmer / embedded hardware engineer in a hardware design group. A few years ago I've convinced my co-workers to use Perl for scripting (instead of a weird mixture of batch files, Excel, Matlab and TCL). Since then, I myself have switched from Perl to Python and am very happy about the change. I want to somehow convince my coworkers to follow my path, but I need good points to convince them. These can't be heavy programmer voodoo like better reflection facilities (unlike myself, most people here are EE graduates and not programmers).

有什么想法吗?关于该主题的好文章/演示文稿?也许有人已经这样做了,可以分享技巧.

Any ideas ? Good articles / presentations on the topic ? Perhaps someone has already done it and can share tips.

注意:

这个帖子有点在同一个主题,但不太符合我的要求.

This thread is somewhat on the same topic, but not quite fits my requirements.

推荐答案

当两种语言具有相似的功能时,将大量代码从一种相似的语言重写为另一种语言并没有什么好处.也许您应该专注于编写更好的 perl 代码.也许学习使用 perltidy,或者购买 Perl Best Practices 和 Perl Medic 的副本,然后将它们分发给您的同事.如果您担心 Perl 不像 Python 那样完全面向对象,请使用 Moose(我会反驳说,与 Perl 相比,函数式编程部门缺少 Python).

There's no benefits to rewriting a ton of code from one similar language to another when both languages have similar capabilities. Perhaps you should focus on writing better perl code. Maybe learn to use perltidy, or buy a copies of Perl Best Practices and Perl Medic, and hand them out to your co-workers. And if you're worried about Perl being not-quite-as-purely OO as Python, use Moose (and I'd counter that Python is lacking in the functional programming department compared to Perl anyway).

针对下面的评论,我还要说,强迫您的同事学习和掌握与您已经使用的语言功能相似的语言是没有意义的.

In response to the comments below, I'll also say that there's no point to forcing your coworkers to learn and get up to speed on a language with similar capabilities to the one you're already using.

现在,如果有一些库或贵公司需要的库在 Python 中可用(或远远优于),而在 Perl 中不可用(或质量低得多),那么继续切换或添加另一种语言到混合.

Now, if there's some library or such that your company needs that is available (or far superior) in Python that is not available (or of far lesser quality) in Perl, then go ahead and switch or add another language to the mix.

这篇关于从 Perl 切换到 Python 的演示的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆