Code Syntax Promotion Suggestion

Operator


Normal Operator

Add spaces at the front and end of the operator.

1+1

1+1

while(low<high){...}

while(low<high){...}

Function Operator (C/C++)

Add spaces at the front and end of the operator.

cin>>n;

cin>>n;

Puncuation Character

Add a space at the end of the puncuation character.

int i,m,n;

int i,m,n;

for(i=1;i<max;i=i*10){...}

for(i = 1;i < max;i = i * 10){...}

Indent


Use Tab but NOT Space !

Hard Tab, I recommend to use.

Actually, I don't mind if you only use Space. But! YOU CANNOT USE BOTH TAB AND SPACE TO INDENT YOUR CODE! Remember that in your heart! Please!

Recommend Tools


  • VS Code / Atom / Sublime Text

    Some people ask me why I don't recommend Vim / Emacs, because their script may be a little hard to the fresh, VS Code / Atom / Sublime Text is enough to them.

  • Visual Studio

    The best programming platform, the richest Integrated Development Enviornment I have ever used.

    分享到:

1 条评论

Arrangement about Web Dev – TripleZ · 2017年3月21日 下午3:40

[…] Code Syatax Promotion Suggestion […]

发表评论

电子邮件地址不会被公开。 必填项已用*标注

验证码 *