Category:J
This programming language may be used to instruct a computer to perform a task.
Official website |
---|
Execution method: | Interpreted |
---|---|
Type safety: | Safe |
Type strength: | Strong (but regular) |
Type checking: | Dynamic |
Lang tag(s): | j |
See Also: |
the J language
J is a notational programming language designed for interactive use.
It is an array language; data is universally structured as rectangular arrays.
It is a functional language; creation and composition of functions is emphasized.
Object-module and imperative techniques are supported, but not required.
The J programming language was designed and developed by Ken Iverson and Roger Hui. It is a closely related successor to APL, also by Iverson which itself was a successor to the notation Ken Iverson used to teach his classes about computers in the 1950s.
Reading J
J is meant to be read with the aid of a computer. J sentences are single lines and trying variations and simplifications of an expression is common practice. The first step in understanding any J sentence is to understand the data you started with and the data which resulted. When learning how a J sentence works, you can also try simpler sentences with the same data or perhaps related data.
Unless you attend an institution which has made a J interpreter available to you through your web browser (or preinstalled on your machine), if you want to see how J works you should probably install a copy of J -- or you can try one of the "try me" links, below. If you want to understand how to experiment with alternative expressions you should probably study some of its documentation.
For example, the phrase (+/ % #)
finds the average of a list of numbers.
<lang J> (+/ % #) 1 2 3 2</lang>
To understand how this works, you might try working with simpler sentences and their variations.
<lang J> +/ 1 2 3 6
+/4 5 6
15
# 1 2 3
3
# 2 3 4
3
6 % 3
2
15 % 3
5
(+/ % #) 4 5 6
5</lang>
By themselves, these experiments mean nothing, but if you know that +/ was finding the sum of a list and # was finding the length of a list and that % was dividing the two quantities (and looks almost like one of the classical division symbols) then these experiments might help confirm that you have understood things properly.
J on RosettaCode
Discussion of the goals of the J community on RC and general guidelines for presenting J solutions takes place at House Style.
Jers on RosettaCode
- Roger Hui: contributions, J wiki
- Tracy Harms: contributions, J wiki
- Dan Bron: contributions, J wiki
- Arie Groeneveld: contributions
- Raul Miller: contributions, J wiki
- Jose Quintana: contributions, J wiki
- Ric Sherlock: contributions, J wiki
- Avmich: contributions
- VZC: contributions
- Alex 'bathala' Rufon: contributions, J wiki
- David Lambert:contributions
try me
Want to try one of those cryptic J lines you see peppered through RC? Try pasting it into the web interface for buubot (broken link) (a Perl IRC bot which has a J evaluation mode: just prefix your line with jeval).
If you want to be a bit more interactive, and get some guidance from J gurus, you can join the actual J IRC channel on Freenode, #jsoftware. Buubot and several other J eval bots run there. If you don't have an IRC client you can try freenode's web interface (or just give it a quick spin). More details about the J IRC community is available.
If any of that piques your interest, and you want to explore a little more, you can download J and join the J forums.
Subcategories
This category has the following 3 subcategories, out of 3 total.
@
- J examples needing attention (1 P)
- J Implementations (empty)
- J User (39 P)
Pages in category "J"
The following 200 pages are in this category, out of 1,413 total.
(previous page) (next page)N
- Negative base numbers
- Neighbour primes
- Nested function
- Nested templated data
- Next highest int from digits
- Next special primes
- Nice primes
- Nim game
- Nimber arithmetic
- Non-continuous subsequences
- Non-decimal radices/Convert
- Non-decimal radices/Input
- Non-decimal radices/Output
- Non-transitive dice
- Nonoblock
- Nth root
- Null object
- Number names
- Number reversal game
- Numbers divisible by their individual digits, but not by the product of their digits.
- Numbers in base 10 that are palindromic in bases 2, 4, and 16
- Numbers in base-16 representation that cannot be written with decimal digits
- Numbers k such that the last letter of k is the same as the first letter of k+1
- Numbers which are not the sum of distinct squares
- Numbers which are the cube roots of the product of their proper divisors
- Numbers whose binary and ternary digit sums are prime
- Numbers whose count of divisors is prime
- Numbers with equal rises and falls
- Numbers with prime digits whose sum is 13
- Numbers with same digit set in base 10 and base 16
- Numeric error propagation
- Numerical integration
- Numerical integration/Adaptive Simpson's method
- Numerical integration/Gauss-Legendre Quadrature
O
- O'Halloran numbers
- Object serialization
- Odd and square numbers
- Odd squarefree semiprimes
- Odd word problem
- Odd words
- Old lady swallowed a fly
- Old Russian measure of length
- One of n lines in a file
- One-dimensional cellular automata
- One-time pad
- One-two primes
- OpenGL
- OpenGL/Utah teapot
- Operator precedence
- Optional parameters
- Orbital elements
- Order by pair comparisons
- Order disjoint list items
- Order two numerical lists
- Ordered partitions
- Ordered words
- Ormiston pairs
- Ormiston triples
- Own digits power sum
P
- Padovan n-step number sequences
- Padovan sequence
- Pairs with common factors
- Palindrome dates
- Palindrome detection
- Palindromic gapful numbers
- Palindromic primes
- Palindromic primes in base 16
- Pan base non-primes
- Pandigital prime
- Pangram checker
- Paraffins
- Parallel calculations
- Parametric polymorphism
- Parse an IP Address
- Parse command-line arguments
- Parsing/RPN calculator algorithm
- Parsing/RPN to infix conversion
- Parsing/Shunting-yard algorithm
- Partial function application
- Particle swarm optimization
- Partition an integer x into n primes
- Partition function P
- Pascal matrix generation
- Pascal's triangle
- Pascal's triangle/Puzzle
- Password generator
- Pathological floating point problems
- Peano curve
- Pell numbers
- Pell's equation
- Penholodigital squares
- Penney's game
- Penrose tiling
- Penta-power prime seeds
- Pentagram
- Percentage difference between images
- Percolation/Mean cluster density
- Percolation/Mean run density
- Percolation/Site percolation
- Perfect numbers
- Perfect shuffle
- Perfect totient numbers
- Periodic table
- Perlin noise
- Permutation test
- Permutations
- Permutations by swapping
- Permutations with repetitions
- Permutations with some identical elements
- Permutations/Derangements
- Permutations/Rank of a permutation
- Permuted multiples
- Pernicious numbers
- Phrase reversals
- Pi
- Pick random element
- Pierpont primes
- Pig the dice game
- Pig the dice game/Player
- Pinstripe/Display
- Piprimes
- Plasma effect
- Playfair cipher
- Playing cards
- Plot coordinate pairs
- Pointers and references
- Poker hand analyser
- Polymorphic copy
- Polymorphism
- Polynomial derivative
- Polynomial long division
- Polynomial regression
- Polynomial synthetic division
- Polyspiral
- Population count
- Positive decimal integers with the digit 1 occurring exactly twice
- Power set
- Practical numbers
- Pragmatic directives
- Price fraction
- Primality by trial division
- Primality by Wilson's theorem
- Prime conspiracy
- Prime decomposition
- Prime numbers p for which the sum of primes less than or equal to p is prime
- Prime numbers which contain 123
- Prime numbers whose neighboring pairs are tetraprimes
- Prime reciprocal sum
- Prime triangle
- Prime triplets
- Prime words
- Primes - allocate descendants to their ancestors
- Primes which contain only one odd digit
- Primes whose first and last number is 3
- Primes whose sum of digits is 25
- Primes with digits in nondecreasing order
- Primes: n*2^m+1
- Primorial numbers
- Print debugging statement
- Print itself
- Priority queue
- Probabilistic choice
- Problem of Apollonius
- Product of divisors
- Product of min and max prime factors
- Program name
- Program termination
- Proof
- Proper divisors
- Protecting Memory Secrets
- Pseudo-random numbers/Middle-square method
- Pseudo-random numbers/PCG32
- Pythagoras tree
- Pythagorean quadruples
- Pythagorean triples
Q
R
- Radical of an integer
- Railway circuit
- Ramanujan primes
- Ramanujan primes/twins
- Ramanujan's constant
- Ramer-Douglas-Peucker line simplification
- Ramsey's theorem
- Random Latin squares
- Random number generator (device)
- Random number generator (included)
- Random numbers
- Range consolidation
- Range expansion
- Range extraction
- Ranking methods
- Rare numbers
- Pages using duplicate arguments in template calls
- Execution method/Interpreted
- Typing/Safe
- Typing/Strong (but regular)
- Typing/Checking/Dynamic
- Programming Languages
- Programming paradigm/Dynamic
- Programming paradigm/Functional
- Programming paradigm/Imperative
- Programming paradigm/Procedural
- Programming paradigm/Reflective
- Programming paradigm/Tacit