Pascal
'''Pascal''' is an imperative computer programming language, developed in 1970 by Niklaus Wirth as a language particularly suitable for structured programming. A derivative known as Object Pascal was designed for object-oriented programming. Pascal can be used very easily in conjunction with fundamental discrete mathematics as sets are built into the language.
There are actually several varieties of Pascal. The most important ones are:
- Standard Pascal (ISO 7185) is the original Pascal standard. However, there are many features missing from that language version, which has led to a wide variety of nonstandard extensions. On the other hand, there are features of Standard Pascal which are seldom implemented by Pascal compilers. A compiler which implements all features of Standard Pascal is GNU Pascal.
- Extended Pascal (ISO 10206) is a later Pascal standard which adds a lot to the original Pascal standard. However, compilers implementing Extended Pascal are even more rare than those implementing Standard Pascal. GNU Pascal implements most of Extended Pascal as well.
- Turbo Pascal was a very successful Pascal implementation for DOS and 16 bit Windows (the latest version was sold under the name "Borland Pascal 7.0") and became the de-facto standard for Pascal on DOS. Even today many Pascal compilers provide compatibility to Turbo Pascal.
- Object Pascal is the Pascal dialect used in Delphi, Borland's successor product to Turbo/Borland Pascal. It extends Pascal with a new object model (in addition to the object model introduced in Turbo Pascal 5.5). This language is also implemented by Free Pascal and Lazarus.
Grammar
The ISO 7185 standard for Pascal uses Extended Backus–Naur Form. Also Van Wijngaarden's grammar can be used to define Pascal's grammarhttp://www-users.cs.york.ac.uk/~fisher/software/yoyovwg/exs/pascal.vwg.
See also
Tasks
- 100 doors
- 15 Puzzle Game
- 15 puzzle solver
- 4-rings or 4-squares puzzle
- A+B
- ABC Problem
- AKS test for primes
- Abundant, deficient and perfect number classifications
- Ackermann function
- Address of a variable
- Align columns
- Almost prime
- Amicable pairs
- Anagrams
- Angle difference between two bearings
- Animation
- Anti-primes
- Apply a callback to an array
- Arbitrary-precision integers (included)
- Arena storage pool
- Arithmetic evaluation
- Arithmetic-geometric mean
- Arithmetic/Complex
- Arithmetic/Integer
- Array concatenation
- Array length
- Arrays
- Assertions
- Averages/Arithmetic mean
- Averages/Mean angle
- Averages/Median
- Averages/Pythagorean means
- Averages/Simple moving average
- Babbage problem
- Balanced brackets
- Benford's law
- Best shuffle
- Binary digits
- Binary search
- Binary strings
- Bitmap
- Bitwise operations
- Boolean values
- Box the compass
- Brazilian numbers
- Bresenham's Line Algorithm
- Bulls and cows
- CSV data manipulation
- Caesar cipher
- Calculating the value of e
- Call a foreign-language function
- Call a function in a shared library
- Case-sensitivity of identifiers
- Catalan numbers
- Catalan numbers/Pascal's triangle
- Catamorphism
- Chaos game
- Character codes
- Check that file exists
- Cholesky decomposition
- Chowla numbers
- Classes
- Closest-pair problem
- Collections
- Combinations
- Comma quibbling
- Command-line arguments
- Comments
- Compile-time calculation
- Compound data type
- Conditional structures
- Copy a string
- Count in factors
- Count in octal
- Count occurrences of a substring
- Create a file
- Create a two-dimensional array at runtime
- Create an HTML table
- Create an object at a given address
- Cuban primes
- Cumulative standard deviation
- Damm algorithm
- Date format
- Date manipulation
- Day of the week
- Define a primitive data type
- Delegates
- Delete a file
- Detect division by zero
- Determine if a string is numeric
- Digital root
- Dining philosophers
- Discordian date
- Dot product
- Doubly-linked list/Element definition
- Doubly-linked list/Element insertion
- Doubly-linked list/Traversal
- Dragon curve
- Draw a cuboid
- Draw a sphere
- Elementary cellular automaton/Random Number Generator
- Emirp primes
- Empty program
- Empty string
- Enforced immutability
- Entropy
- Enumerations
- Equilibrium index
- Ethiopian multiplication
- Euler method
- Euler's sum of powers conjecture
- Evaluate binomial coefficients
- Even or odd
- Evolutionary algorithm
- Exceptions/Catch an exception thrown in a nested call
- Execute Brainfuck
- Execute a system command
- Exponentiation operator
- Extreme floating point values
- FASTA format
- Factorial
- Factors of a Mersenne number
- Factors of an integer
- Farey sequence
- Fibonacci n-step number sequences
- Fibonacci sequence
- Fibonacci word
- Filter
- Find limit of recursion
- Find the missing permutation
- Finite state machine
- First perfect square in base N with N unique digits
- Five weekends
- Fixed length records
- FizzBuzz
- Flow-control structures
- Floyd's triangle
- Formatted numeric output
- Forward difference
- Function composition
- Function definition
- Fusc sequence
- Generate lower case ASCII alphabet
- Generic swap
- Globally replace text in several files
- Gray code
- Greatest common divisor
- Greatest element of a list
- Greatest subsequential sum
- Guess the number
- Guess the number/With feedback
- Guess the number/With feedback (player)
- HTTP
- HTTPS
- Hailstone sequence
- Hamming numbers
- Happy numbers
- Harshad or Niven series
- Hash from two arrays
- Haversine formula
- Hello world!
- Hello world/Graphical
- Hello world/Line printer
- Hello world/Newline omission
- Hello world/Standard error
- Hello world/Text
- Heronian triangles
- Hexapawn
- Higher-order functions
- Hofstadter Q sequence
- Hofstadter-Conway $10,000 sequence
- Horizontal sundial calculations
- Horner's rule for polynomial evaluation
- Host introspection
- Hostname
- Identity matrix
- Image noise
- Include a file
- Increment a numerical string
- Infinity
- Inheritance/Multiple
- Inheritance/Single
- Input loop
- Integer comparison
- Integer sequence
- Iterated digits squaring
- Jaro distance
- Jensen's Device
- Keyboard input/Obtain a Y or N response
- Knapsack problem/0-1
- Knapsack problem/Unbounded
- Knuth shuffle
- Langton's ant
- Largest int from concatenated ints
- Leap year
- Least common multiple
- Letter frequency
- Levenshtein distance
- Linear congruential generator
- Literals/Floating point
- Literals/Integer
- Literals/String
- Logical operations
- Long multiplication
- Long primes
- Longest common subsequence
- Longest string challenge
- Look-and-say sequence
- Loop over multiple arrays simultaneously
- Loops/Break
- Loops/Do-while
- Loops/Downward for
- Loops/For
- Loops/For with a specified step
- Loops/Foreach
- Loops/Infinite
- Loops/N plus one half
- Loops/Nested
- Loops/While
- Lucas-Lehmer test
- Ludic numbers
- Luhn test of credit card numbers
- Machine code
- Mad Libs
- Magic squares of odd order
- Man or boy test
- Mandelbrot set
- Map range
- Matrix transposition
- Maximum triangle path sum
- Memory allocation
- Memory layout of a data structure
- Menu
- Mian-Chowla sequence
- Middle three digits
- Modular exponentiation
- Modular inverse
- Modulinos
- Monte Carlo methods
- Monty Hall problem
- Morse code
- Multiple distinct objects
- Multiplication tables
- Munchausen numbers
- Mutual recursion
- N-body problem
- N-queens problem
- N-smooth numbers
- Naming conventions
- Narcissistic decimal number
- Natural sorting
- Nested function
- Non-decimal radices/Convert
- Nth root
- Null object
- Number names
- Numerical integration
- Numerical integration/Gauss-Legendre Quadrature
- One of n lines in a file
- One-dimensional cellular automata
- OpenGL
- Operator precedence
- Palindrome detection
- Pangram checker
- Paraffins
- Parametrized SQL statement
- Pascal matrix generation
- Pascal's triangle
- Password generator
- Penney's game
- Perceptron
- Perfect numbers
- Perfect totient numbers
- Permutations
- Permutations with repetitions
- Pernicious numbers
- Pi
- Pig the dice game
- Playing cards
- Pointers and references
- Polymorphism
- Population count
- Price fraction
- Primality by trial division
- Prime conspiracy
- Prime decomposition
- Primorial numbers
- Program name
- Proper divisors
- Pythagorean quadruples
- Pythagorean triples
- Quaternion type
- Queue/Definition
- Quine
- Random number generator (device)
- Random number generator (included)
- Random numbers
- Range extraction
- Read a configuration file
- Read a file line by line
- Read a specific line from a file
- Read entire file
- Real constants and functions
- Regular expressions
- Remove duplicate elements
- Remove lines from a file
- Rename a file
- Repeat a string
- Reverse a string
- Reverse words in a string
- Roman numerals/Encode
- Roots of a function
- Roots of a quadratic function
- Roots of unity
- Rot-13
- Run-length encoding
- Runge-Kutta method
- SEDOLs
- SHA-1
- Safe primes and unsafe primes
- Scope modifiers
- Search a list
- Secure temporary file
- Self-describing numbers
- Semiprime
- Sequence of primes by trial division
- Sequence: smallest number greater than previous term with exactly n divisors
- Set
- Sexy primes
- Shell one-liner
- Short-circuit evaluation
- Show the epoch
- Sierpinski carpet
- Sierpinski triangle
- Sieve of Eratosthenes
- Simple windowed application
- Singly-linked list/Element definition
- Singly-linked list/Element insertion
- Singly-linked list/Traversal
- Sleep
- Smith numbers
- Sockets
- Sort an array of composite structures
- Sort stability
- Sort using a custom comparator
- Sorting Algorithms/Circle Sort
- Sorting algorithms/Bead sort
- Sorting algorithms/Bogosort
- Sorting algorithms/Bubble sort
- Sorting algorithms/Cocktail sort
- Sorting algorithms/Comb sort
- Sorting algorithms/Counting sort
- Sorting algorithms/Gnome sort
- Sorting algorithms/Heapsort
- Sorting algorithms/Insertion sort
- Sorting algorithms/Merge sort
- Sorting algorithms/Pancake sort
- Sorting algorithms/Quicksort
- Sorting algorithms/Selection sort
- Sorting algorithms/Shell sort
- Sorting algorithms/Stooge sort
- Sorting algorithms/Strand sort
- Soundex
- Special characters
- Spiral matrix
- Square but not cube
- Stack
- Stair-climbing puzzle
- Start from a main routine
- Statistics/Normal distribution
- Stern-Brocot sequence
- String append
- String case
- String concatenation
- String length
- String prepend
- Strip a set of characters from a string
- Strip comments from a string
- Strip control codes and extended characters from a string
- Strong and weak primes
- Subleq
- Substring
- Substring/Top and tail
- Sudoku
- Sum and product of an array
- Sum data type
- Sum digits of an integer
- Sum multiples of 3 and 5
- Sum of a series
- Sum of squares
- Sum to 100
- Symmetric difference
- System time
- Take notes on the command line
- Taxicab numbers
- Temperature conversion
- Terminal control/Clear the screen
- Terminal control/Coloured text
- Terminal control/Cursor positioning
- Terminal control/Display an extended character
- Terminal control/Inverse video
- Terminal control/Ringing the terminal bell
- Ternary logic
- Test a function
- The ISAAC Cipher
- The Twelve Days of Christmas
- Thue-Morse
- Tokenize a string
- Top rank per group
- Topological sort
- Totient function
- Transportation problem
- Trigonometric functions
- Truncate a file
- Truth table
- Twelve statements
- Two Sum
- Ulam spiral (for primes)
- Undefined values
- Universal Turing machine
- Unix/ls
- Use another language to call a function
- Van Eck sequence
- Van der Corput sequence
- Variable size/Get
- Variable size/Set
- Variables
- Variadic function
- Vector products
- Vigenère cipher
- Walk a directory/Non-recursively
- Window creation
- Window creation/X11
- Write entire file
- Write float arrays to a text file
- XML/DOM serialization
- Xiaolin Wu's line algorithm
- Yin and yang
- Zero to the zero power
- Zig-zag matrix