Примеры перевода
Lopulliseen dokumenttiin tulostuu vain se kirjallisuus, johon on viitattu Latex-dokumentissa.
The major exception to this is the so-called fine print in legal documents.
Tässä esimerkissä teksti tulostuu terminaaliin: Public Sub Main() Print "Hello World!"
Here is the console version of a Hello world program: PROC main: PRINT "Hello World!"
Voisimme käyttää TECOa tähän vaikka seuraavalla tavalla (asteriski on kehote, ja dollarimerkki kuvastaa ESC-näppäimen painallusta): *EBterve.c$$ Avataan tiedosto lukemista ja kirjoittamista varten *P$$ Luetaan ensimmäinen sivu *STerve$0TT$$ Etsitään sanaa "Terve" ja tulostetaan ko. rivi printf("Terve, maailma!\n"); Tulostuu... *-5DIHyvästi$0TT$$ Poistetaan "Terve", vaihdetaan tilalle "Hyvästi", ja tulostetaan rivi printf("Hyvästi, maailma!\n"); Tulostuu... *EX$$ Poistutaan TECOsta samalla tallentaen Tämä artikkeli perustuu osittain Jargon File -dokumenttiin (public domain).
TECO commands are characters (including control-characters), and the prompt is a single asterisk: * The escape key displays as a dollar sign, pressed once it delineates the end of a command requiring an argument and pressed twice initiates the execution of the entered commands: *$$ Given a file named hello.c with the following contents: int main(int argc, char **argv) { printf("Hello world!\n"); return 0; } one could use the following TECO session (noting that the prompt is "*" and "$" is how ESC is echoed) to change "Hello" into "Goodbye": *EBhello.c$$ Open file for read/write with backup *P$$ Read in the first page *SHello$0TT$$ Search for "Hello" and print the line (pointer placed after searched string) printf("Hello world!\n"); The line *-5DIGoodbye$0TT$$ Delete five characters before pointer (ie "Hello"), insert "Goodbye", and print the line printf("Goodbye world!\n"); The updated line *EX$$ Copy the remainder of the file and exit These two example programs are a simple interchange sort of the current text buffer, based on the 1st character of each line, taken from the PDP-11 TECO User's Guide.
How many English words do you know?
Test your English vocabulary size, and measure how many words you know.
Online Test