Common VI commands and vimrc Configuration

Source: Internet
Author: User
Tags control characters

· A simple Compiler (Compiling and executing common programs) # vi ~ /. Vimrc "defines F9 to compile and execute the Program Map <F9>: Call progcompilerun () <CR> func progcompilerun ()" s *** e the current file first: W "Get the extension name of the program, such as J *** a php pl py let ext = expand (" %: e ") "compile J *** A if ext =" J *** a "If expand (" %: H ")! = "":! J *** AC % & J *** A-classpath expand ("%: H") %: T: r else :! J *** AC % & J *** a %: T: R endif return endif "execute PHP if ext =" php ":! PHP % return endif "compile and execute C/CC/CPP if ext =" C "| ext =" cc "| ext =" CPP ":! GCC %-o a. Out &./A. Out return endif "compile and execute Perl if ext =" PL ":! Perl-C % return endif "compile and execute Python if ext =" py ":! Python % return endif endfunc

Source:

Http://hi.baidu.com/yanyulou/blog/item/728ba344709aea81b3b7dc6d.html


Path Matching:

In insert mode, replace the first few characters in the input path with ^ x ^ F (^ X is <Control + x>). A matched menu appears at the bottom of the screen, consecutive selection by ^ F, you can also use <Control + n>

And <Control + P>.

 

Multi-line comment:
:., + 3 S/^/#/g comment the last three rows starting from the current row (excluding the current row)

VI replacement command usage details:

Reference : Ranges/pat1/pat2/GC
Where
: This is the VI Command Execution interface.
Ranges specifies the command execution range. You can use percent sign (%) to indicate all rows, dot (.) To represent the current row, and dollar sign ($) to represent the last row. You can also use the row number. For example, 10, 20 indicates 10th to 20 rows ,., $ indicates the current row to the last row ,. + 2, $-5 indicates the last two rows of the current row until the bottom line of the full text, and so on.

S indicates a replacement command.
Pat1This is a regular expression to be searched.
Pat2This is a regular expression that converts the matching string to the pattern.
GOptional. This flag indicates that the replacement will be performed for each matching string in the row. Otherwise, only the first matching string in the row will be replaced. COptional flag to check whether the current match is replaced.

----------------------------------------

Common VI operations (Comprehensive)

1) File Operations
VI filename open the file filename and place the cursor at the beginning of the first line.
Vi + N filename open the file filename and place the cursor at the beginning of line N.
Vi + filename open the file filename and place the cursor in the last line.
Vi +/pattern file open the file and place the cursor at the first string matching pattern.
VI-r filename is restored after a system crash occurs when the file name is edited by VI last time.
VI file1... Filen open multiple files and edit them one by one.

: %! Xxd view the current file in hexadecimal format
: %! Xxd-r returns normal mode from hexadecimal

: N1, N2 W! Command takes the content from line N1 to line N2 in the file as the command input and runs it,
If N1 and N2 are not specified, the entire file content is used as the command input.
: R! Command: place the output result of the command to the current line.
: So <File> Read <File>, and then execute the commands in the file (the commands in the file should all be some ex commands)
: W> <File> Add to <File> end. You can also use the row number.
: E! Reedit the current file and ignore all modifications.

· (, [, {,},],) Corresponding display
% Displays the corresponding items of the current (, [, {,},],)
) Display the corresponding (
) Display the corresponding [
] Display the corresponding {

· (, [, {,},],) Data selection
Dab deletes {} and its content (in non-V visual mode)
DiB deletes content in {}
Content in AB selection ()
Content in IB selection () (excluding ())

Content selected in AB {}
Select Content in IB {} (excluding {})

· Syntax prompt and Automatic completion

★<C-N> <C-P> Automatic completion of words in insert mode
★<C-X> <C-L> automatic line completion (super useful)

· Set ctags
# Ctags-F/usr/share/Vim/vim63/funcs. Tags-r/opt/j2sdk/src/usr/src/kernels/2.6.9-5. EL-i686

^ P automatically fills in similar context items
^ N auto-completion ~ /. Similar functions in tags
^ [Display ~ /. The prototype of the function under the cursor in tags,
Exit the function by ^ t.
: The PTA function name preview window quickly opens the file where the corresponding function is located, and positions the cursor at the beginning of the corresponding function
K. Man manual for displaying C functions under the cursor

· Variable locating
GD goes to the definition of the local variable under the cursor
GD goes to the definition of the global variable under the cursor

· Compilation options
: The CN command will take you to the next error location, regardless of the file in which it is located.
: The CC command will show you the compiler output information of the current error;
: CL will generate a list of all project errors in the column for viewing these errors

· Word
W or W move one word to the beginning of the word to the right of the cursor.
B or B move one word left to the beginning of the word.
E or E move one word to the end of the word to the right of the cursor.

· Sentence} move the cursor to the end of the sentence.
(Move the cursor to the beginning of the sentence.

· Segment) move the cursor to the beginning of the paragraph.
{Move the cursor to the end of the paragraph.

· Move a row up with the cursor K or Ctrl + P.
J or Ctrl + n move the cursor down a row.
Enter: move the cursor down a row.
Ng cursor moves to the beginning of line N.
N + move the cursor down n rows.
N-move n rows above the cursor.
N $ move the cursor to the end of line N.
0 move the cursor to the beginning of the current row.
$ Move the cursor to the end of the current row.

· Screen
H move the cursor to the top line of the screen.
M move the cursor to the middle line of the screen.
L move the cursor to the last line of the screen.
CTRL + u to the first half of the screen.
CTRL + D flip the half screen to the end of the file.
CTRL + F.
CTRL + B.
NZ rolls row n to the top of the screen. If n is not specified, the current row is rolled to the top of the screen.

4} insert

# Insert the row number in the file (not the display line number, but the insert !)
★: G/^/exec "s/^/". strpart (line ("."). "", 0, 4)

· Cursor
I insert before the cursor.
A is inserted after the cursor.

· Line
I is inserted at the beginning of the current row.
A is inserted at the end of the current row.
O Insert a new row under the current row.
O Insert a new row above the current row.

5) replace
R replaces the current character.
R replaces the current character with the subsequent character until you Press ESC.
S starts from the current cursor position and replaces the specified number of characters with the input text.
S deletes the specified number of rows and replaces them with the input text.

6) modify
NCW or NCW modifies a specified number of characters.
NCC modifies a specified number of rows.
: R filename: insert the file filename under the current row.

7) search and replace

/<C-R> <C-W> write narrow word <cword> to search Command Line
/<C-R> <C-A> write generalized word <cword> to search Command Line

: G/str/S/str1/str2/g
The first G indicates that each row including S1 is replaced,
The second g Represents replacing all of the rows.
Replace str1 with str2 for all rows including Str
: % S/F $/for $/g Replace the "f" (F key and Space key) at the end of each line with the
: % S/^/MV/g Add "mv" (MV key and Space key) to the header of each line)

: S/Fred/<c-r> A/G replace Fred with the content in register.

: G/<input | <form/P displays rows containing <input or <form

# Replacing a visual area
# Select a region and enter S/Emacs/Vim/. Vim automatically enters the mode.
: '<,'> '<,'> Before S/Emacs/Vim/G '<,'> is automatically added by VIM.

# Search for multiple documents
: Bufdo/searchstr
: Argdo/searchstr

Copy and cut
The position of two characters before and after the XP Switch
Exchange the positions of the upper and lower rows of DDP
: G/Fred/T $ copy the row from Fred to the end of the file (EOF)

9) window operations
: VNE [filename]
: SP [filename]
: S [filename]
: New [filename]
: ^ W + ^ r swap the positions of the two windows
^ W = window width
: Res-N window height reduced by N
: Res + n increase the window height n
: Vert res-n
: Vert res + n

10) convert dos text to UNIX text
: 1, $ S/^ m/g

11) bookmarks
When reading and writing large program files, it is very helpful to use the tag (bookmarks) function to locate them.
Move the cursor to the position you want to mark. If you make a tag named "debug1", you can enter the tag command "mdebug1" in command mode, and then press the Enter key, A tag named "debug1" is ready.

Next, you can move the cursor to another position at will. When you enter "'debug1" in command mode, you can quickly return to the first line of the line marked by "debug1.

12) Delete
: % S/R // G press enter to delete dos ^ m
: % S = * $ = Delete the blank space at the end of the row
: % S/^ (. *) N1/1 $/delete duplicate rows
: % S/^. {-} PDF/newusers/only deletes the first PDF
: % S/<! -- _. {-} --> // Delete the multi-line comment (comment? Why do we say "again ?)

: G/^ s * $/d delete all empty rows
: G! /^ DD/d Delete the row without the string 'dd'
: V/^ DD/d same as above (translated as V = G !, Is not matched !)
: G/str1/,/str2/d delete all the rows from the first entry containing str1 to the first entry containing str2.
: V/./,/./-1 Join compressed empty rows
: G/^ $/,/./-J compressed empty rows

Ndw or ndw deletes n-1 characters starting at and following the cursor.
Delete D0 to the beginning of the row.
D $ Delete to the end of the row.
NDD deletes the current row and the next n-1 row.
Delete a character from X or X.
CTRL + u Delete the text entered in the input mode.
^ R restore u
J. Merge the next row to the end of the current row
V select a row
^ V press ^ V to select a rectangle.
Aw select word
IW internal words (no space)
As Select sentence
Is Select sentence (no space)
AP selection Section
IP selection section (no space)
D. Delete it to the end of the row.
X, Y Delete and copy contain highlight Area

DL deletes the current character (same as the X command)
D0 is deleted to the starting position of a row.
D ^ Delete the first character (excluding spaces or tab characters) to a row)
DW is deleted to the end of a word.
D3w is deleted to the end of the third word.
DB is deleted to the start position of a word.
DW is deleted to the end of a word with a space as the separator.
DB is deleted to the start position of a word with space as the separator.
D7b is deleted to the start position of the first seven words with spaces as separators.
D) Delete to the end of a statement
D4) to the end of the fourth statement.
D (delete to the start position of a statement)
D) delete it to the end of a paragraph.
D {Delete to the beginning of a paragraph
D7 {Delete the first 7th paragraph positions before the start position of the current paragraph
Dd deletes the current row
D/Text: Delete the position specified by "text" from the text,
Forward until the content of the next occurrence (but not including the word)
DFC deletes the position where the character "C" appears from the text and continues until the next occurrence of the character (including the character ).
DTC deletes the content from the current row until the next character "C" appears
D. Delete it to the end of a row.
D $ Delete to the end of a row
5dd Delete the contents of the five rows starting from the current row
Delete DL content until the last line on the screen
DH Delete until the first line of content on the screen
Delete content from the DG until the end of the work Cache
D1g Delete content that begins in the work Cache
Modify command operation
R change current character
CW to the end of a word
Modify c3w to the end of the third word
Change CB to the start position of a word
CW changes to the end position of a word with a space as the separator.
CB is changed to the start position of a word with spaces as the separator.
C7b is changed to the start position of the first seven words with spaces as separators.
C0 to the end of a row
C} modify to the end of a statement
C4} changed to the end of the fourth statement.
C (modify to the starting position of a statement)
C) modify it to the end of a paragraph.
C {modify to the start position of a paragraph
C7 {change to the first 7th paragraph positions before the current paragraph start position
CTC modifies the content of the current row until the next character C appears
C. modify it to the end of a row.
CC modify current row
5 cc modify the content of 5 rows starting from the current row
. Repeat the previous modification!

13} set options
Set all lists the settings of all options.
Set term to set the terminal type.
Set ignorecase ignores case sensitivity in search.
Set List displays the stop (^ I) and end signs ($ ).
Set number indicates the row number.
Set showmode indicates the mode in which the user is located.
Set report displays the number of rows in the Country modified by the line-oriented command.
Set terse displays brief warning information.
When set warn is transferred to another file, no write information is displayed if the current file is not saved.
Set autowrite in ": N" and ":!" The file is automatically saved before the command.
Set nomagic allows you to use special characters that do not contain/before in search mode.
Set nowrapscan prohibits VI from starting from the other end when the search reaches both ends of the file.
Set mesg allows VI to display the information that other users write to their terminal using write.

Autoindent (AI) noai makes the new line automatically indent, and alignment with the position of the upper (lower) Row
After each command of autoprint (AP) AP, the changes are displayed.
Autowrite (AW) noaw at: N ,:! The file is automatically saved before the command.
Beautify (BF) nobf ignores all control characters (except tab, newline, and formfeed) during input ))
Directory = (DIR =)/tmp directory name for storing the buffer
Usage of edcompatible noedcompatible Class Ed when replacing
Errorbells (EB) errorbells rings when an error occurs
Exrc (Ex) noexrc allows the. exrc file to be placed outside the home directory.
Hardtabs = (ht =) 8. Set the boundary of the hard tabulation.
Ignore case (IC) noic in the regular expression ignore case sensitivity
Lisp nolisp open the lisp Mode
List nolist displays all tabulation keys and the end of a row
Magic agic can use more regular expressions
Mesg allows sending messages to terminals
Number (Nu) nonumber display row number
Open allows openness and Visualization
Optimize (OPT) Optimize optimizes throughput, and press Enter when printing
Paragraphs = (para =) iplpppqpplibp sets the {&} delimiter
In prompt command mode, the following prompt is displayed:
Readonly (RO) Noro unless used! No. Otherwise, the file cannot be saved.
Redraw noredraw redraws the screen when editing
Remap remap allows macros to point to other macros
Report = 5 if the number of affected rows is greater than this number, report
The number of scrolling screens in the scroll 1/2 window, which is also the number of lines output by the Z command (twice the size of the screen)
Sections = shnhh Hu defines the end of the section (when the command [[and] is used)
Shell = (SH =)/bin/sh default shell. If the environment variable shell is set, use the variable
Shiftwidth = (SW =) 8 number of characters that are moved when the shift command is used
Showmatch (SM) nosm shows matching conditions of {,}, (,), [, or]
Showmode noshowmode shows the mode in which you are in.
Do not update the display immediately after slowopen (slow) is inserted.
Tabstop = (TS =) 8. Set the length of tabstop.
Taglength = (TL =) 0 Number of important characters (0 indicates all characters)
Tags = tag,/usr/lib/tags defines the file path containing the tag
Term = set the terminal type
Terse noterse displays brief error messages
Timeout (to) Timeout: the keyboard ing times out after one second
Ttytype = set the terminal type
Warn warn displays "no write since last change" Information
Window = (W =) number of rows in the visible mode
Wrapmargin = (WM =) 0 right margin. If it is greater than 0, the rightmost word will be broken, leaving n blank positions
Wrapscan (WS) WS finds the end of the file and starts starting with another header.
Writeany (WA) Nowa can be saved to any file

14} special characters
^ The matched string is at the beginning of the line.
$ The matched string is at the end of the line.
. Used in a pattern string to indicate any single character.
In command mode, repeat the previous command.
* In a mode string, the prefix can appear multiple times.
[] Is used in a mode string to indicate characters in the specified azimuth, where "-" indicates a word.
Character range. Use ^ to indicate characters that are not in a certain range.
ESC switches from the insert status to the command status
^ [Same function as ESC

15] case-sensitive Conversion
Guu row lower case
Guu rows in uppercase
G ~~ Line flip (case sensitive)

<G id = "1"> guw </G>
Guw uppercase (narrow words)
G ~ W-word flip (narrow words)

Veu uppercase (generalized)
Ve ~ Word flip (generalized word)

Gggug writes the entire article in lower case (FT! BT !)

16) Jump to the footprint. Jump to the last modified line (super useful) (FT, how is this comment)
'. Not only the last modified line, but also the modification point.
<C-O> jump back to your redirect record (from the last time)
<C-I> jump forward along your jump record in turn
: Ju (MPS) to list your jumps

17) command history
: History: List historical Command records
: His C command line command history
: His s SEARCH Command history
Q/window for searching command history
Q command line command history window
: <C-F> history Command record window

18] registers
# List registers (registers)
: Reg: display all current registers
"1 p indicates referencing register, 1 indicates a register named 1, and P indicates the paste command.

Explanation:
"Also used to define register
Enter "to define register
Enter the name, for example, 0 ~ 9, ~ Z
Then run the delete or Copy command, such as DD or Y,
Or D (delete the selected part) or Y (copy the selected part) in visual mode)
The deleted or copied part is stored in the named register.

Observation: a special register, "", contains an anonymous delete/copy
When you execute DD or Y, the affected part is saved "".

19} command line
"Ayy @ A runs the current line as a Vim command
Explanation: "Ayy defines the current row to register a, and @ A executes the commands stored in register.

10yy Copy 10 rows below the current row

11} sorting
: %! Sort-u uses the sort program to sort the entire file (rewrite the file with the result)
! 1) sort-u sort the current section (it can only be used in Normal Mode !!)
:., + 5! Sort sorts the current row and the following five rows

20) Column Operations

: % S = [^] + $ = & = copy the last column
: % S = F + $ =& & = same features
: % S = S + $ = & ft, same

: S/(. *). *)/2 "1/Use: Split two fields

: % S (W + S +) {2}) str1: 1str2: process column, replace all str1 In the third column

: % Sw +) (. * s +) (W +) $: 321: swap the first and last columns (4 columns in total)

·. Vimrc

"Use Vim settings, rather then VI settings (much better !).
Set nocompatible

"C-style indent
: Set expandtab "use spaces instead of tabs
: Set cindent shiftwidth = 4

"Auto indent
: Set AI

"Syntax
": Set filetype = J ***
: Set syntax = J ***

"Type),],}, display (,[,{
: Set showmatch

"Manual folding
: Set foldmethod = manual

"Tag File Location
Set tags =/usr/share/Vim/vim63/funcs. tags

"In insert mode, press [CTRL] n to automatically complete any class, method, or field name.
Set complete + = K

"Don't bother me with your voice!
Set visualbell

"History
: Set history = 50

"Display row and column positions
: Set ruler

"Set character encoding
Set fileencodings = gb2312
"Set encoding = EUC-CN

"Set ruler
Set ruler

"Display current command
Set showcmd

"Incsearch
Set incsearch

"Allow backspacing over everything in insert mode
Set backspace = indent, EOL, start

"Automatically detect file types
: Filetype on

"Shortcut key definition """"""""""""""""""""""""""" """"""""""""""""""""""""""""""""
If version> = 600

"Search
"Map <C-H>/

"Search function prototype
Map <C-H> yiw/^/(/S/) */(sub/) // |/(function/)/(/S /) * <c-r> "<CR>

"Continue searching
Map <F3> N

"Use <F10> to display the list of classes, attributes, and methods
Map <F2>: tlist <CR>

"Compile the current program with the Compilation Program defined by Compiler
"Map <F9>: Make" % "<CR>

"Use <F11> for PHP syntax Detection
Map <F11> :! Php-L "%" <CR>

Map; W: Call formattext () <CR>

"Search for words under the current cursor
Map <F4>/<C-R> <C-W> <CR>
Endif
""""""""""":: Shortcut Key definition """""""""""""""""""""""""""""""""""""" """""""""""""""""""

"Format File """"""""""""""""""""""""""" """"""""""""""""""""""""""""""""
Function formattext ()
: % S // t // G "to replace/T with four spaces
: % S/* $ // G "Remove spaces at the end of the line

Endfunction

"Format File """"""""""""""""""""""""""" """"""""""""""""""""""""""""""""

"Display the tabs and extra spaces at the end of a line """""""""""""""""""""" """""""""""""""""""""""""
Set listchars = tab:>-, trail :~
Set list
Syntax match trail "+ $"
Highlight def link trail todo

"""""""""":: Display the tab and extra spaces at the end of a line """""""""""""""""""""""""""""""" """""""""""""

Function lastmod ()
If line ("$")> 5
Let L = 5
Else
Let L = line ("$ ")
Endif
EXE "1 ,". l. "/cnsprogcmtime/S/cnsprogcmtime. */cnsprogcmtime ". strftime ("% Y-% m-% d % H: % m: % s "). "/E"

Endfunction

"Map <F5>: Call lastmod () <CR>

"Automatically adds an asterisk """"""""""""""""""""""" """""""""""""""""""""""""""""
"When Using comments such as/*... */, r inserts a value when pressing enter in insert mode *;
"O is inserted when" O "or" O "is used in Normal Mode *
: Set formatoptions = tcro

""""""""""":: Automatically add the * Asterisk """""""""""""""""""""""""""""""""" """"""""""""""""

VI Extension Regular Expression

| Indicates alternating, for example, home | House indicates matching the home or house

() Used for grouping, such as home | house can be written as Ho (Me | use)
* You can use () (home | house) * to match home, homehouse, househome, and homehousehomehouse.

/(.../) The actual matched text can be searched using the replacement part of the replacement command, such as/1 and/2.

+ The regular expression can be matched once or multiple times, including a single character, (), or (.../), at least once.
Ho (use | Me) + indicates that at least house or home cannot be empty.

? Indicates the occurrence or absence of zero or one occurrence of the previous regular expression. Such as free? D will match Fred or freed. This cannot match other texts.

{...} Defines an interval expression. The interval expression describes the number of duplicates. Same /{.../}
{N} (home | house) {2} can only match homehome, homehouse, househome, househouse
{N ,}
{N, m}
{, N}

Compilation

· Use a compiler to compile the current file
:! Perl-C %
:! Php-l % Use PHP to check errors
:! Php-Q % Use PHP to run the program

· Compile the current program as a. Out and execute this./A. Out
:! GCC %-o a. Out &./A. Out
Execution result
Old umask is % #0
New umask is % #0

· Compilation error message
: CL! List details of all error messages

: CL: list the current error message
: CN: list the next error message
: CP: list the previous error message

: Number of latest cnew error messages
: Number of old cold error messages

: CWIN or: Copen open the error message window
: CClose close the information window opened above

Auto-completion

CTRL-X CTRL-F file name
CTRL-X CTRL-L whole line
CTRL-X CTRL-D macro definition (and search for included files)
CTRL-X CTRL-I current file and included file
Words in CTRL-X CTRL-K dictionary files
Words in CTRL-X CTRL-T synonym dictionary files
CTRL-X Ctrl-] Mark
CTRL-X CTRL-V Vim command line

C Program Design

The GD reversed color shows all the occurrences of the local identifier string under the cursor and goes to the first occurrence.
The GD reversed color shows all the occurrences of the global identifier string under the cursor and goes to the first occurrence.

Bytes --------------------------------------------------------------------------------------

: Checkpath: list all include header files
Bytes --------------------------------------------------------------------------------------

[I display function definitions
Extern _ mode_t umask (_ mode_t _ mask) _ Throw;

Bytes --------------------------------------------------------------------------------------

[+ Ctrl + I jump to [Function Definition marked by I
Listing [I list the current file and the rows containing the current characters in the file

Statement [D: display the Definition Statement of the identifier defined by # define

Printf (| Tom );
# Define Tom "yaoshuyin"
Bytes --------------------------------------------------------------------------------------

CTRL +] Jump to the label at the current position of the cursor (for example, the definition of a function ).
CTRL + t jump to the place before executing Ctrl-] command.
: Tselect selects one from a series of matching tags.

[// Jump to the start position of the comment.
]/Jump to the end of the comment.

----------------------------------------------------------------

[# Return to unclosed # If, # ifdef, or # Else.
] # Move forward to unclosed # else or # endif.

[(Return to unclosed.
) Forward to the unclosed.

[{Jump to the nearest.
} Jump to the nearest.

· Character Set and hexadecimal conversion
Ga displays the ASCII, Hex, Oct,... heap conversion of the characters at the cursor

For example, press ga before S
<S> 115, Hex 73, octal 163

Column block Operation

<C-V> selected column Blocks
I <string> <ESC> Add a string to the beginning of each line of the block
A <string> <ESC> Add a string at the end of each line of the block
C <string> <ESC> modify the selected column block (delete and enter new content)
C <string> <ESC> modify the selected column block (delete and enter new content)
> Left-shift tab width

File Name and Path in vimrc

For example, in D:/cnscnprogrames/Vim/vim63/, edit VI tmp/file. j *** A (I .e. D:/cnscnprogrames/Vim/vim63/tmp/file. j ***)

Expand ("%") # tmp/file. j ***
Expand ("%: P") # D:/cnscnprogrames/Vim/vim63/tmp/file. j ***
Expand ("%: H") # TMP
Expand ("%: t") # file. j ***
Expand ("%: e") # J ***
Expand ("%: T: R") # File
Expand ("%: R") # tmp/File

· A simple Compiler (Compiling and executing common programs) # vi ~ /. Vimrc "defines F9 to compile and execute the Program Map <F9>: Call progcompilerun () <CR> func progcompilerun ()" s *** e the current file first: W "Get the extension of the program, such as J ***
Php pl py let ext = expand ("%: e") "compile J *** A if ext =" J *** a "If expand (" %: H ")! = "":! J *** AC % & J *** A-classpath expand ("%: H") %: T: r else :! J *** AC % & J *** a %: T: R endif return endif "execute PHP if ext =" php ":! PHP % return endif "compile and execute C/CC/CPP if ext =" C"
| Ext = "cc" | ext = "CPP ":! GCC %-o a. Out &./A. Out return endif "compile and execute Perl if ext =" PL ":! Perl-C % return endif "compile and execute Python if ext =" py ":! Python % return endif endfunc

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.