程序员要注意的几句英文句子!

原文连接:
http://www.winprog.org/english/

theForger's English For Programmers

Introduction

One of the wonderful things about IRC, and the Internet at large is that it allows people of all nations to come together in peace to discuss, debate and learn. English is of course, the de facto standard language of the Internet (at least for now...) and while this is great for North Americans and most Europeans, you can expect some difficulty in communication between people who are not native English speakers and have had most of their English exposure from the Internet itself (oh, the humanity).

For some reason, certain specific and erronous patterns of speech are common, and I would like to provide a simple reference for the would-be English speaking programmer.

Anyone knows...?

For example Anyone knows how to create a window?. I can understand the origin of this statement, as it may make grammatical sense in certain languages. In fact it must make sense in many languages other than English, otherwise I can't see how so many people of different origins managed to mistakenly use the same phrase when asking a question in English.

The correct sentence structure would be Does anyone know how to create a window?

Anyone knows...? (wrong)
Does anyone know...? (right)

ne1!?

As surprising as it may seem, ne1 isn't actually a real English word (I kid you not). Often used in combination with the previous entry, as in Does ne1 how to create a window?, or the even more extremely incorrect ne1 knows how to create a window?

ne1 (wrong)
Anyone (right)

How to...?

Another variation on this theme, for example how to load a icon??? This is also a very common mistake made by those whose native language is not English. You could use one of the previously mentioned sentence structures instead, or you have the option of going with How can I load an icon?, How do you load an icon? or the more pretentious, but also acceptable How does one load an icon?.

How to... (wrong)
How can I... (right)
How do you... (right)
How does one... (right)

I have a doubt...

Somewhere in the world, an evil dictionary publisher is laughing. They managed to print all of their dictionaries with the word doubt replacing the word question. Generally in English, one does not have a doubt about something. You may have a question about something or even have a problem with something.

I have a doubt... (wrong)
I have a question about... (right)
I have a problem with... (right)
I am having trouble with... (right)

What's the command in C++?

C and C++ do not have commands, they have functions. C++ also has member functions (a function which is a member of a class) which may also be referred to as a method. A function which is not a member of a class is not a method.

C/C++ also have statements and expressions. A statement is generally any line of code that does something. An expression is something that evaluates to another value, such as an addition, bit shift, or logical comparison.

command (wrong)
function (right)
method (right)

or possibly (depending on the circumstances)...
expression
statement

 
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值