https://aplwiki.com/api.php?action=feedcontributions&user=SteveAllen0112&feedformat=atomAPL Wiki - User contributions [en-gb]2024-03-28T21:35:00ZUser contributionsMediaWiki 1.38.2https://aplwiki.com/index.php?title=Talk:Jobs&diff=8564Talk:Jobs2022-05-20T17:24:26Z<p>SteveAllen0112: /* Needed: Senior Software Engineer (added: 2022-05-20) */ Edit to summarize and link out instead of show the whole posting.</p>
<hr />
<div>{{#css:[rel="discussion"],#ca-addsection a{visibility:hidden}[rel="discussion"]:before{visibility:visible;content:"Job listings";position:absolute}.mw-redirectedfrom{display:none}#ca-addsection a:before{visibility:visible;content:"Add item";position:absolute} }}{{DISPLAYTITLE:Job listings}}<br />
This page is open for declarations of ability to provide APL consultancy, availability for hire, and job openings.<br />
<br />
* '''[{{fullurl:{{TALKPAGENAME}}|action=edit&section=new&preloadtitle=Needed:%20%5Bshort%20description%20here%5D%20(added:%20{{CURRENTYEAR}}-{{CURRENTMONTH}}-{{CURRENTDAY2}})}} Click here to add a new listing for an open job position.]'''<br />
<br />
* '''[{{fullurl:{{TALKPAGENAME}}|action=edit&section=new&preloadtitle=Available:%20%5Bshort%20description%20here%5D%20(added:%20{{CURRENTYEAR}}-{{CURRENTMONTH}}-{{CURRENTDAY2}})}} Click here to add a new listing advertising an available programmer.]'''<br />
<br />
Note that this page is not for communication about the listing, so make sure to include contact information. <br />
<br />
While this page is monitored and moderated, as per the [[APL_Wiki:general disclaimer|general disclaimer]]s, APL Wiki takes no responsibility for its content, nor is any listing here endorsed by APL Wiki, its contributors, or its sponsors.<br />
__TOC__<br />
<!-- == Careers at Dyalog Ltd. (added: 2021-03-04) ==<br />
<br />
[[Dyalog Ltd.|We]] do not currently have any open positions. However, if you think you might have the right skills for roles like the ones that we have most recently filled (described on [https://www.dyalog.com/careers.htm our careers page]), please forward your resume to [mailto:careers@dyalog.com careers@dyalog.com]. We may need to grow [https://www.dyalog.com/meet-team-dyalog.htm the team] again at short notice, and it would be good to know you are out there!<br />
--><br />
== Available: APL programmer with extensive experience (added: 2021-03-04) ==<br />
<br />
I have been interested in APL for 42 years, and have been a programmer for 35 years, using NARS2000 APL for the last decade and half or so.<br />
<br />
I'm in Baltimore, Maryland, USA, and I'm not really able to travel. Since our department imploded, I haven't been able to find a job in my field because the languages I know, no one hires for, and the ones they are looking for, I don't have job experience in. No one wants to take me on as entry level, because I have too much experience, so I have been working as a math tutor since the summer of '19. I do, however, know APL. For example, I solved 121 of the project Euler problems using it.<br />
<br />
Contact [https://www.linkedin.com/in/michael-turniansky-057604177/ me on LinkedIn] if you have an opening for me.<br />
<br />
== Needed: APL Developer with strong working knowledge of APL (added: 2021-03-08) ==<br />
<br />
The APL Developer works with a group of associates within the Technical Operations and Product Engineering teams who advise InvestCloud financial management clients on industry best practices related to trading proposal, reporting and workflow while also providing daily support for existing customized solutions. Under general supervision, our developers follow standard practices and procedures to analyze, modify, test and support application software systems. The ideal candidate is a self-starter, motivated and brings enthusiasm to his/her work with "can do" attitude to join our growing team. This role will expose you to a wide variety of technologies and you can expect to be helping to provide solutions to complex problems.<br />
<br />
[https://recruiting.ultipro.com/TEG1001TEGR/JobBoard/ad4204e8-c7f7-47f1-8177-c9f64730dccc/OpportunityDetail?opportunityId=4c42bc41-0d11-4a5f-a3d0-71e7934c9909 Details…]<br />
<br />
== Available: workshops in APL (added: 2021-04-03) ==<br />
<br />
Despite working for [[Dyalog Ltd.]] almost full-time, Rodrigo also organises and promotes academic workshops on subjects related to mathematics and programming. Some of those workshops are a great way of introducing people to APL. Feel free to take a look at [https://mathspp.com/education/workshops some past workshops Rodrigo has led] if you need inspiration or [https://mathspp.com/about#contacts contact him] if you would like Rodrigo to organise one of these workshops for you/a group you represent.<br />
<br />
== Needed: APL Developer (added: 2021-06-07) ==<br />
<br />
Hi,<br />
<br />
This is Vinny Sanchez from Genzeon Corporation.<br />
<br />
We are looking to fill a APL developer with one of our Direct clients. If you are interested, please share your updated resume ASAP.<br />
<br />
Job Title: APL developer<br />
Location: Remote/ Occasional travel to Philadelphia, PA for meetings<br />
Duration: 12–24 Months contract<br />
<br />
Job Description:<br />
Searching for an APL developer, mostly maintenance/support but some new coding for enhancements, etc.. <br />
<br />
The client runs an older COLI/BOLI system (SOLAR) that still pays out on policies bought during the 80’s and 90’s. COLI/BOLI is corporate/bank owned life insurance. Companies/banks/etc bought life insurance policies on their employees and customers as long-term investments. They don’t sell them anymore, but they must pay out on them until they all expire. The solar system manages all those policies and was written in APL. It scrapes the social security database every night to see if any policy holder names died the day before and then processes the policy payout. <br />
<br />
Regards,<br />
<br />
Vinny Sanchez | Sr Technical Recruiter <br />
Direct: 484-713-8976<br />
Email: Vinny.Sanchez@genzeon.com<br />
<br />
== Needed: Video editing volunteer (added: 2021-07-05) ==<br />
<br />
[[BAA]] needs help editing the recordings of [[BAA Webinar|their webinars]] so they may be published on YouTube. If you have even basic video editing skills and are interested in watching these recordings anyway, then this may well be a good task for you. '''Note that this is an unpaid volunteer job.'''<br />
<br />
Contact: [mailto:editor@britishaplassociation.org editor@britishaplassociation.org]<br />
<br />
== Needed: Programmer/Language Implementor at Dyalog Ltd (added: 2022-04-06) ==<br />
<br />
Are you a C programmer who is eager to dig into unusual tasks? Here's your chance to join our development team, working on our core product; an implementation of the array-oriented programming language APL, including its interpreter, optimised array operations, interfaces to the outside world, compilers, and various tools.<br />
<br />
We have a hybrid work environment, with main offices in two idyllic locations: Bramley, Hampshire (U.K.) and Hellebæk (Denmark). The ability to spend time in one of the offices on a regular basis is important, but you can apply if you are fluent in English, no matter where you live. A few employees work principally from their homes in Europe or the United States.<br />
<br />
See [https://www.dyalog.com/careers.htm#progimpl Dyalog's website] for details.<br />
<br />
== Needed: APL programmers in various locations (added: 2022-05-16) ==<br />
<br />
[[wikipedia:SimCorp|SimCorp]] needs several positions filled in various locations (current as of 2022-05-16 — [https://www.simcorp.com/en/search-results?q=apl%20job search current positions here]):<br />
{| class=wikitable<br />
! Title !! Location(s) !! Deadline<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/devops-engineer-r202817 DevOps Engineer] || Manila, PH; Warsaw, PL <br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/senior-software-engineer-quality-assurance-for-investment-operations-r202982 Senior Software Engineer (QA)] || Warsaw, PL || 2022-06-30 07:00 <br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/software-engineer-development-for-investment-operations-r202974 Software Engineer (devt)] || Warsaw, PL || 2022-06-30 07:00<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/software-engineer-for-collateral-management-r203077 Software Engineer for Collateral Management] || Warsaw, PL || 2022-05-22 07:00 <br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/software-engineer-c-ocamland-apl-r202453 Software Engineer, C#, OCaml and APL] || Warsaw, PL<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/senior-software-engineer-r201422 Senior Software Engineer] || Kyiv, UA<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/senior-software-engineer-r202395 Senior Software Engineer] || Kyiv, UA<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/business-oriented-software-engineer-r201805 Business oriented Software Engineer] || Kyiv, UA<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/senior-software-engineer-c--alternative-investments-frankfurt-r202812 (Senior) Software Engineer C#] || Frankfurt/Bad Homburg, DE<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/lead-software-engineer-r202882 Lead Software Engineer] || Copenhagen, DK (headquarters) || 2022-06-30 07:00<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/graduate-software-engineer--functional-programming-r202935 Graduate Software Engineer] || Copenhagen, DK (headquarters)<br />
|-<br />
|}<br />
<br />
== Needed: Senior Software Engineer (added: 2022-05-20) ==<br />
<br />
InvestCloud is looking for an APL-experienced Senior Software Engineer with additional skills in MSSQL/Oracle, Java, AIX, & Linux or Shell scripting.<br />
Leadership position.<br />
<br />
The Job Posting can be found [https://www.linkedin.com/jobs/view/3062740205/ here].</div>SteveAllen0112https://aplwiki.com/index.php?title=Talk:Jobs&diff=8562Talk:Jobs2022-05-20T17:17:37Z<p>SteveAllen0112: /* Needed: Senior Software Engineer (added: 2022-05-20) */ new section</p>
<hr />
<div>{{#css:[rel="discussion"],#ca-addsection a{visibility:hidden}[rel="discussion"]:before{visibility:visible;content:"Job listings";position:absolute}.mw-redirectedfrom{display:none}#ca-addsection a:before{visibility:visible;content:"Add item";position:absolute} }}{{DISPLAYTITLE:Job listings}}<br />
This page is open for declarations of ability to provide APL consultancy, availability for hire, and job openings.<br />
<br />
* '''[{{fullurl:{{TALKPAGENAME}}|action=edit&section=new&preloadtitle=Needed:%20%5Bshort%20description%20here%5D%20(added:%20{{CURRENTYEAR}}-{{CURRENTMONTH}}-{{CURRENTDAY2}})}} Click here to add a new listing for an open job position.]'''<br />
<br />
* '''[{{fullurl:{{TALKPAGENAME}}|action=edit&section=new&preloadtitle=Available:%20%5Bshort%20description%20here%5D%20(added:%20{{CURRENTYEAR}}-{{CURRENTMONTH}}-{{CURRENTDAY2}})}} Click here to add a new listing advertising an available programmer.]'''<br />
<br />
Note that this page is not for communication about the listing, so make sure to include contact information. <br />
<br />
While this page is monitored and moderated, as per the [[APL_Wiki:general disclaimer|general disclaimer]]s, APL Wiki takes no responsibility for its content, nor is any listing here endorsed by APL Wiki, its contributors, or its sponsors.<br />
__TOC__<br />
<!-- == Careers at Dyalog Ltd. (added: 2021-03-04) ==<br />
<br />
[[Dyalog Ltd.|We]] do not currently have any open positions. However, if you think you might have the right skills for roles like the ones that we have most recently filled (described on [https://www.dyalog.com/careers.htm our careers page]), please forward your resume to [mailto:careers@dyalog.com careers@dyalog.com]. We may need to grow [https://www.dyalog.com/meet-team-dyalog.htm the team] again at short notice, and it would be good to know you are out there!<br />
--><br />
== Available: APL programmer with extensive experience (added: 2021-03-04) ==<br />
<br />
I have been interested in APL for 42 years, and have been a programmer for 35 years, using NARS2000 APL for the last decade and half or so.<br />
<br />
I'm in Baltimore, Maryland, USA, and I'm not really able to travel. Since our department imploded, I haven't been able to find a job in my field because the languages I know, no one hires for, and the ones they are looking for, I don't have job experience in. No one wants to take me on as entry level, because I have too much experience, so I have been working as a math tutor since the summer of '19. I do, however, know APL. For example, I solved 121 of the project Euler problems using it.<br />
<br />
Contact [https://www.linkedin.com/in/michael-turniansky-057604177/ me on LinkedIn] if you have an opening for me.<br />
<br />
== Needed: APL Developer with strong working knowledge of APL (added: 2021-03-08) ==<br />
<br />
The APL Developer works with a group of associates within the Technical Operations and Product Engineering teams who advise InvestCloud financial management clients on industry best practices related to trading proposal, reporting and workflow while also providing daily support for existing customized solutions. Under general supervision, our developers follow standard practices and procedures to analyze, modify, test and support application software systems. The ideal candidate is a self-starter, motivated and brings enthusiasm to his/her work with "can do" attitude to join our growing team. This role will expose you to a wide variety of technologies and you can expect to be helping to provide solutions to complex problems.<br />
<br />
[https://recruiting.ultipro.com/TEG1001TEGR/JobBoard/ad4204e8-c7f7-47f1-8177-c9f64730dccc/OpportunityDetail?opportunityId=4c42bc41-0d11-4a5f-a3d0-71e7934c9909 Details…]<br />
<br />
== Available: workshops in APL (added: 2021-04-03) ==<br />
<br />
Despite working for [[Dyalog Ltd.]] almost full-time, Rodrigo also organises and promotes academic workshops on subjects related to mathematics and programming. Some of those workshops are a great way of introducing people to APL. Feel free to take a look at [https://mathspp.com/education/workshops some past workshops Rodrigo has led] if you need inspiration or [https://mathspp.com/about#contacts contact him] if you would like Rodrigo to organise one of these workshops for you/a group you represent.<br />
<br />
== Needed: APL Developer (added: 2021-06-07) ==<br />
<br />
Hi,<br />
<br />
This is Vinny Sanchez from Genzeon Corporation.<br />
<br />
We are looking to fill a APL developer with one of our Direct clients. If you are interested, please share your updated resume ASAP.<br />
<br />
Job Title: APL developer<br />
Location: Remote/ Occasional travel to Philadelphia, PA for meetings<br />
Duration: 12–24 Months contract<br />
<br />
Job Description:<br />
Searching for an APL developer, mostly maintenance/support but some new coding for enhancements, etc.. <br />
<br />
The client runs an older COLI/BOLI system (SOLAR) that still pays out on policies bought during the 80’s and 90’s. COLI/BOLI is corporate/bank owned life insurance. Companies/banks/etc bought life insurance policies on their employees and customers as long-term investments. They don’t sell them anymore, but they must pay out on them until they all expire. The solar system manages all those policies and was written in APL. It scrapes the social security database every night to see if any policy holder names died the day before and then processes the policy payout. <br />
<br />
Regards,<br />
<br />
Vinny Sanchez | Sr Technical Recruiter <br />
Direct: 484-713-8976<br />
Email: Vinny.Sanchez@genzeon.com<br />
<br />
== Needed: Video editing volunteer (added: 2021-07-05) ==<br />
<br />
[[BAA]] needs help editing the recordings of [[BAA Webinar|their webinars]] so they may be published on YouTube. If you have even basic video editing skills and are interested in watching these recordings anyway, then this may well be a good task for you. '''Note that this is an unpaid volunteer job.'''<br />
<br />
Contact: [mailto:editor@britishaplassociation.org editor@britishaplassociation.org]<br />
<br />
== Needed: Programmer/Language Implementor at Dyalog Ltd (added: 2022-04-06) ==<br />
<br />
Are you a C programmer who is eager to dig into unusual tasks? Here's your chance to join our development team, working on our core product; an implementation of the array-oriented programming language APL, including its interpreter, optimised array operations, interfaces to the outside world, compilers, and various tools.<br />
<br />
We have a hybrid work environment, with main offices in two idyllic locations: Bramley, Hampshire (U.K.) and Hellebæk (Denmark). The ability to spend time in one of the offices on a regular basis is important, but you can apply if you are fluent in English, no matter where you live. A few employees work principally from their homes in Europe or the United States.<br />
<br />
See [https://www.dyalog.com/careers.htm#progimpl Dyalog's website] for details.<br />
<br />
== Needed: APL programmers in various locations (added: 2022-05-16) ==<br />
<br />
[[wikipedia:SimCorp|SimCorp]] needs several positions filled in various locations (current as of 2022-05-16 — [https://www.simcorp.com/en/search-results?q=apl%20job search current positions here]):<br />
{| class=wikitable<br />
! Title !! Location(s) !! Deadline<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/devops-engineer-r202817 DevOps Engineer] || Manila, PH; Warsaw, PL <br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/senior-software-engineer-quality-assurance-for-investment-operations-r202982 Senior Software Engineer (QA)] || Warsaw, PL || 2022-06-30 07:00 <br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/software-engineer-development-for-investment-operations-r202974 Software Engineer (devt)] || Warsaw, PL || 2022-06-30 07:00<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/software-engineer-for-collateral-management-r203077 Software Engineer for Collateral Management] || Warsaw, PL || 2022-05-22 07:00 <br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/software-engineer-c-ocamland-apl-r202453 Software Engineer, C#, OCaml and APL] || Warsaw, PL<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/senior-software-engineer-r201422 Senior Software Engineer] || Kyiv, UA<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/senior-software-engineer-r202395 Senior Software Engineer] || Kyiv, UA<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/business-oriented-software-engineer-r201805 Business oriented Software Engineer] || Kyiv, UA<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/senior-software-engineer-c--alternative-investments-frankfurt-r202812 (Senior) Software Engineer C#] || Frankfurt/Bad Homburg, DE<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/lead-software-engineer-r202882 Lead Software Engineer] || Copenhagen, DK (headquarters) || 2022-06-30 07:00<br />
|-<br />
| [https://www.simcorp.com/en/career/find-a-job/graduate-software-engineer--functional-programming-r202935 Graduate Software Engineer] || Copenhagen, DK (headquarters)<br />
|-<br />
|}<br />
<br />
== Needed: Senior Software Engineer (added: 2022-05-20) ==<br />
<br />
==== What does a great Senior Product Engineer do? ====<br />
<br />
Here at InvestCloud as a Senior Product Engineer you will serve as a technical leader in the application support development team. Ensuring that client issues are resolved as quickly as possible with high attention to quality. The application support team plays a key role in supporting industry leading software for our customers that require support on rotational basis. With over 450 clients, we work with cross functional teams in a highly matrixed environment. You will work closely with product development team and other stakeholders to share your learning to improve product development for our customers. You will find this opportunity rewarding if you thrive in a fast-paced environment, have a passion for developing others, and are comfortable holding others accountable. As a senior resource you will have the opportunity to work on a wide variety of projects, where you can apply your existing knowledge to take on new market problems on almost a daily basis. We operate in a highly collaborative environment; working with other skilled software professionals to deliver high quality software and professional support to help clients improve the way they do business.<br />
<br />
==== Basic Qualifications for Consideration: ====<br />
* Experience with Software Engineering, APL (A Programming Language) willing to be trained and learn new language.<br />
* Experience in Unix (AIX) or Linux/Shell Scripting<br />
* Knowledge of Relational Database (MS SQL Server & Oracle)/SQL<br />
* Java, MQ, Linux any combination.<br />
* A solid understanding of computer programming, data structures, algorithms, software development patterns and platform testing.<br />
* An advanced understanding of software application troubleshooting techniques<br />
* Ability to communicate effectively, as this position will build consensus with numerous internal and external resources and effectively influence technical direction of projects to be successful.<br />
* Ability to determine the best implementation approach/methodology for assigned project(s) based on established guidelines and standard methodologies and figures out appropriate strategy for ensuring desired objectives.<br />
* Strong analytical skills<br />
<br />
==== Preferred Skills, Experience, and Education: ====<br />
* BS in Computer Science, Software Engineering, or equivalent<br />
* At least 5 years’ experience with APL application development<br />
* Working knowledge of Java, C#, .NET and cloud technologies are plus<br />
<br />
Send CV/Resumes to ctucker@investcloud.com.<br />
<br />
Full-time, W-2, salary plus excellent benefits.<br />
<br />
https://recruiting.ultipro.com/TEG1001TEGR/JobBoard/ad4204e8-c7f7-47f1-8177-c9f64730dccc/Opportunity/OpportunityDetail?opportunityId=dba004c7-bfea-48a7-af7e-be00ee8b2f17</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8532BQN2022-05-18T18:31:01Z<p>SteveAllen0112: </p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and "happens to match the capitals in 'Big Questions Notation'"<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn "What Kind of a Name is BQN?"]</ref>.<br />
<br />
Lochbaum recounts, "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."<ref>[[Marshall Lochbaum]]. [https://chat.stackexchange.com/transcript/message/54753804#54753804 Stack Exchange Transcript]</ref><br />
<br />
Lochbaum commented further on this in Episode 7 of the Array Cast, saying,<br />
<br />
<blockquote><br />
...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN.<br />
<ref>[[Marshall Lochbaum]]. [https://www.arraycast.com/episode-7-transcript The Array Cast, Episode 7]: in response to a question starting at the 11:29 mark</ref><br />
</blockquote><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8531BQN2022-05-18T18:29:58Z<p>SteveAllen0112: </p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and "happens to match the capitals in 'Big Questions Notation'"<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn "What Kind of a Name is BQN?"]</ref>.<br />
<br />
Lochbaum recounts, "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."<ref>[[Marshall Lochbaum]]. [https://chat.stackexchange.com/transcript/message/54753804#54753804 Stack Exchange Transcript]</ref><br />
<br />
Lochbaum commented further on this in Episode 7 of the Array Cast, saying,<br />
<br />
<blockquote><br />
...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN.<br />
<ref>[https://www.arraycast.com/episode-7-transcript The Array Cast, Episode 7]: [[Marshall Lochbaum]], in response to a question starting at the 11:29 mark</ref><br />
</blockquote><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8530BQN2022-05-18T18:27:06Z<p>SteveAllen0112: </p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and "happens to match the capitals in 'Big Questions Notation'"<ref>[https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn][[Marshall Lochbaum]]. "What Kind of a Name is BQN?"</ref>.<br />
<br />
Lochbaum recounts, "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."<ref>[https://chat.stackexchange.com/transcript/message/54753804#54753804][[Marshall Lochbaum]]. Stack Exchange Transcript</ref><br />
<br />
Lochbaum commented further on this in Episode 7 of the Array Cast, saying,<br />
<br />
<blockquote><br />
...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN.<br />
<ref>[https://www.arraycast.com/episode-7-transcript]The Array Cast, Episode 7: [[Marshall Lochbaum]], in response to a question starting at the 11:29 mark</ref><br />
</blockquote><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8529BQN2022-05-18T18:26:31Z<p>SteveAllen0112: </p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and "happens to match the capitals in 'Big Questions Notation'"<ref>[https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn][[Marshall Lochbaum]]. "What Kind of a Name is BQN?"</ref>.<br />
<br />
Lochbaum recounts, "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."<ref>[https://chat.stackexchange.com/transcript/message/54753804#54753804][[Marshall Lochbaum]]. Stack Exchange Transcript</ref><br />
<br />
Lochbaum commented further on this in Episode 7 of the Array Cast], saying,<br />
<br />
<blockquote><br />
...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN.<br />
<ref>[https://www.arraycast.com/episode-7-transcript]The Array Cast, Episode 7: [[Marshall Lochbaum]], in response to a question starting at the 11:29 mark</ref><br />
</blockquote><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8528BQN2022-05-18T18:25:10Z<p>SteveAllen0112: </p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and "happens to match the capitals in 'Big Questions Notation'"<ref>[https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn][[Marshall Lochbaum]]. "What Kind of a Name is BQN?"</ref>.<br />
<br />
[[Marshall Lochbaum]] recounts, "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."<ref>[https://chat.stackexchange.com/transcript/message/54753804#54753804][[Marshall Lochbaum]]. Stack Exchange Transcript</ref><br />
<br />
Lochbaum commented further on this in Episode 7 of the Array Cast], saying,<br />
<br />
<blockquote><br />
...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN.<br />
<ref>[https://www.arraycast.com/episode-7-transcript]The Array Cast, Episode 7: [[Marshall Lochbaum]], in response to a question starting at the 11:29 mark</ref><br />
</blockquote><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8527BQN2022-05-18T18:23:09Z<p>SteveAllen0112: </p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and "happens to match the capitals in 'Big Questions Notation'"<ref>[https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn][[Marshall Lochbaum]]. "What Kind of a Name is BQN?"</ref>.<br />
<br />
[[Marshall Lochbaum]] recounts, "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."<ref>[https://chat.stackexchange.com/transcript/message/54753804#54753804][[Marshall Lochbaum]]. Stack Exchange Transcript</ref><br />
<br />
Lochbaum commented further on this in Episode 7 of the Array Cast], saying, "...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN." <ref>[https://www.arraycast.com/episode-7-transcript]The Array Cast, Episode 7: [[Marshall Lochbaum]], in response to a question starting at the 11:29 mark</ref><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8526BQN2022-05-18T18:22:43Z<p>SteveAllen0112: </p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and "happens to match the capitals in 'Big Questions Notation'"<ref>[https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn][[Mashall Lochbaum]]. "What Kind of a Name is BQN?"</ref>.<br />
<br />
[[Marshall Lochbaum]] recounts, "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."<ref>[https://chat.stackexchange.com/transcript/message/54753804#54753804][[Marshall Lochbaum]]. Stack Exchange Transcript</ref><br />
<br />
Lochbaum commented further on this in Episode 7 of the Array Cast], saying, "...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN." <ref>[https://www.arraycast.com/episode-7-transcript]The Array Cast, Episode 7: [[Marshall Lochbaum]], in response to a question starting at the 11:29 mark</ref><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8525BQN2022-05-18T18:19:51Z<p>SteveAllen0112: Change external link to ref.</p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and "happens to match the capitals in 'Big Questions Notation'"<ref>[https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn]</ref>.<br />
<br />
[[Marshall Lochbaum]] recounts, "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."<ref>[https://chat.stackexchange.com/transcript/message/54753804#54753804]</ref> Lochbaum commented further on this in Episode 7 of the Array Cast], saying, "...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN." <ref>[https://www.arraycast.com/episode-7-transcript]in response to a question starting at the 11:29 mark</ref><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8524BQN2022-05-18T18:19:08Z<p>SteveAllen0112: </p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and [https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn "happens to match the capitals in 'Big Questions Notation'"].<br />
<br />
[[Marshall Lochbaum]] recounts, "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."<ref>[https://chat.stackexchange.com/transcript/message/54753804#54753804]</ref> Lochbaum commented further on this in Episode 7 of the Array Cast], saying, "...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN." <ref>[https://www.arraycast.com/episode-7-transcript]in response to a question starting at the 11:29 mark</ref><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8523BQN2022-05-18T18:17:45Z<p>SteveAllen0112: Use references instead of external links, and use last name after first mention instead of first name, per wiki style.</p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and [https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn "happens to match the capitals in 'Big Questions Notation'"].<br />
<br />
[[Marshall Lochbaum]] recounts, <ref>[https://chat.stackexchange.com/transcript/message/54753804#54753804]"I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L."</ref> Lochbaum commented further on this in Episode 7 of the Array Cast], in response to a question starting at the 11:29 mark, saying, <ref>[https://www.arraycast.com/episode-7-transcript] "...the way I came up with the name BQN was I thought, ... alright, I'm working on this next APL. What do I call [it?] ... I took took APL and I moved it forward and I got BQN. And I said, well, BQN, that sounds pretty good... [B]ig Questions Notation is what I ended up with. I like it 'cause it suggests that not only you're solving big questions, but you have big questions about the notation, so it's a little tongue in cheek. And I said also, you can pronounce it like bacon, so there's even a food pun like Apple. And after some half hour or an hour of thinking about this, I realized that the letter that comes after L is M, not N. I think it would be much more logical for N to come first, because it's the letter with two humps. BQM is a horrible, horrible name, and so I stuck with BQN."<br />
</ref><br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=BQN&diff=8522BQN2022-05-18T18:03:29Z<p>SteveAllen0112: Added the section The Name BQN</p>
<hr />
<div>{{Infobox array language<br />
| logo = [[File:BQN logo.png]]<br />
| array model = [[based array model|based]]<br />
| index origin = 0<br />
| function styles = block (like [[dfn]]s), [[tacit]]<br />
| numeric types = 64-bit float<br />
| unicode support = full<br />
| released = 2020<br />
| developer = [[Marshall Lochbaum]]<br />
| latest release version = 2022 (unversioned)<br />
| implementation languages = BQN with [[wikipedia:JavaScript|JavaScript]], [[wikipedia:C (programming language)|C]], or others<ref name="running">[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/running.html "How to run BQN"]</ref><br />
| source = [https://github.com/mlochbaum/BQN GitHub]<br />
| platforms = x86, ARM, in-browser, [[wikipedia:Node.js|Node.js]]<br />
| license = [[wikipedia:ISC license|ISC]]<br />
| website = [https://mlochbaum.github.io/BQN mlochbaum.github.io/BQN]<br />
| file ext = .bqn<br />
| documentation = [https://mlochbaum.github.io/BQN/doc Documentation]<br />
| forum = [https://app.element.io/#/room/%23bqn:matrix.org #bqn:matrix.org]<br />
| influenced by = [[J]], [[A+]], [[Dyalog APL]], [[Co-dfns]], [[APL\iv]], [[wikipedia:JavaScript|JavaScript]]<ref>[[Marshall Lochbaum]]. [https://mlochbaum.github.io/BQN/commentary/history.html "BQN's development history"].</ref><br />
| influenced =<br />
| run online = [https://bqnpad.mechanize.systems/ BQNPAD]<br />
}}<br />
<br />
'''BQN''' is an APL-family language designed primarily by [[Marshall Lochbaum]]. Although it maintains the concept of array-driven computing and much of APL's array functionality, BQN discards all [[backwards compatibility|compatibility]] with other array languages and changes many fundamental concepts. It uses the [[based array model]] with dedicated [[array notation]], distinguishes between data types and expression roles to give the language a [[wikipedia:context-free grammar|context-free grammar]] with [[wikipedia:first-class function|first-class function]]s, and uses a new set of [[glyph]]s with different primitive pairings. The language uses the [[leading axis model]] and [[tacit programming]] as core paradigms. Its implementation is largely self-hosted, with an array-based compiler like [[Co-dfns]].<br />
<br />
== Implementations ==<br />
<br />
BQN has several implementations,<ref name="running"/> with all complete ones based on self-hosted sources, which are compiled to bytecode and included as literal arrays or similar in the implementation's source. [https://github.com/dzaima/CBQN CBQN], developed by [[dzaima]] in [[wikipedia:C (programming language)|C]], is the primary implementation with the best performance. A [[wikipedia:JavaScript|JavaScript]] version can be run online. It's slower than CBQN compiled to [[wikipedia:WebAssembly|Wasm]], but easier to connect with browser functionality.<br />
<br />
The [https://github.com/mlochbaum/Singeli Singeli] language was developed in order to implement BQN more effectively. CBQN uses Singeli for primitive code that uses [[vector instruction]]s, and can be built with or without these optimized implementations. The Singeli implementation is written in BQN and currently targets C.<br />
<br />
=== dzaima/BQN ===<br />
<br />
Now largely replaced by CBQN, dzaima/BQN is [[dzaima]]'s independent implementation in Java, based on [[dzaima/APL]]. While dzaima/APL adds significant new functionality and is different from any other APL, dzaima/BQN follows the BQN specification closely and sometimes extends it with [[system function]]s. It has often been the first implementation to support new functionality, particularly syntax such as block headers, and was the fastest implementation before CBQN was created. It introduced the [[wikipedia:bytecode|bytecode]] format now shared with self-hosted BQN, and was used for development and bootstrapping.<br />
<br />
== Primitives ==<br />
<br />
=== Functions ===<br />
<br />
{|class=wikitable<br />
! Glyph !! Monadic !! Dyadic<br />
|-<br />
| <code>+</code> || [[Conjugate]] || [[Add]]<br />
|-<br />
| <code>-</code> || [[Negate]] || [[Subtract]]<br />
|-<br />
| <code>×</code> || [[Sign]] || [[Multiply]]<br />
|-<br />
| <code>÷</code> || [[Reciprocal]] || [[Divide]]<br />
|-<br />
| <code>⋆</code> || [[Exponential]] || [[Power (function)|Power]]<br />
|-<br />
| <code>√</code> || [[Square Root]] || [[Root]]<br />
|-<br />
| <code>⌊</code> || [[Floor]] || [[Minimum]]<br />
|-<br />
| <code>⌈</code> || [[Ceiling]] || [[Maximum]]<br />
|-<br />
| <code>∧</code> || Sort Up || [[And]]<br />
|-<br />
| <code>∨</code> || Sort Down || [[Or]]<br />
|-<br />
| <code>¬</code> || [[Not]] || Span<br />
|-<br />
| <code><nowiki>|</nowiki></code> || [[Absolute Value]] || [[Residue|Modulus]]<br />
|-<br />
| <code>≤</code> || || [[Less Than or Equal to]]<br />
|-<br />
| <code><</code> || [[Enclose]] || [[Less Than]]<br />
|-<br />
| <code>></code> || [[Mix|Merge]] || [[Greater Than]]<br />
|-<br />
| <code>≥</code> || || [[Greater Than or Equal to]]<br />
|-<br />
| <code>=</code> || [[Rank]] || [[Equals]]<br />
|-<br />
| <code>≠</code> || [[Tally|Length]] || [[Not Equals]]<br />
|-<br />
| <code>≡</code> || [[Depth]] || [[Match]]<br />
|-<br />
| <code>≢</code> || [[Shape]] || [[Not Match]]<br />
|-<br />
| <code>⊣</code> || [[Identity]] || [[Left]]<br />
|-<br />
| <code>⊢</code> || [[Identity]] || [[Right]]<br />
|-<br />
| <code>⥊</code> || [[Ravel|Deshape]] || [[Reshape]]<br />
|-<br />
| <code>∾</code> || [[Raze|Join]] || [[Catenate|Join to]]<br />
|-<br />
| <code>≍</code> || Solo || Couple<br />
|-<br />
| <code>↑</code> || Prefixes || [[Take]]<br />
|-<br />
| <code>↓</code> || Suffixes || [[Drop]]<br />
|-<br />
| <code>↕</code> || [[Index Generator|Range]] || Windows<br />
|-<br />
| <code>»</code> || Nudge || Shift Before<br />
|-<br />
| <code>«</code> || Nudge Back || Shift After<br />
|-<br />
| <code>⌽</code> || [[Reverse]] || [[Rotate]]<br />
|-<br />
| <code>⍉</code> || [[Transpose]] || [[Transpose|Reorder axes]]<br />
|-<br />
| <code>/</code> || [[Indices]] || [[Replicate]]<br />
|-<br />
| <code>⍋</code> || [[Grade|Grade Up]] || [[Interval_Index|Bins Up]]<br />
|-<br />
| <code>⍒</code> || [[Grade|Grade Down]] || [[Interval_Index|Bins Down]]<br />
|-<br />
| <code>⊏</code> || First Cell || [[Select]]<br />
|-<br />
| <code>⊑</code> || [[First]] || Pick<br />
|-<br />
| <code>⊐</code> || Classify || [[Index of]]<br />
|-<br />
| <code>⊒</code> || [[Occurrence Count]] || [[Progressive Index of]]<br />
|-<br />
| <code>∊</code> || [[Unique Mask]] || [[Member of]]<br />
|-<br />
| <code>⍷</code> || [[Unique|Deduplicate]] || [[Find]]<br />
|-<br />
| <code>⊔</code> || Group Indices || Group<br />
|}<br />
<br />
=== Modifiers ===<br />
<br />
[[Monadic operator|1-modifiers]] in BQN use superscript symbols, while [[Dyadic operator|2-modifiers]] use symbols with a circle, but not one with a line through it like <code>⌽</code> and <code>⍉</code>.<br />
<br />
{|<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>˙</code> || [[Constant]]<br />
|-<br />
| <code>˜</code> || [[Commute|Self/Swap]]<br />
|-<br />
| <code>˘</code> || Cells<br />
|-<br />
| <code>¨</code> || [[Each]]<br />
|-<br />
| <code>⌜</code> || [[Outer Product|Table]]<br />
|-<br />
| <code>⁼</code> || Undo<br />
|-<br />
| <code>´</code> || [[Reduce|Fold]]<br />
|-<br />
| <code>˝</code> || [[Reduce|Insert]]<br />
|-<br />
| <code>`</code> || [[Scan]]<br />
|}<br />
|style="vertical-align:top"|<br />
{|class=wikitable<br />
! Glyph !! Name(s)<br />
|-<br />
| <code>∘</code> || [[Atop]]<br />
|-<br />
| <code>○</code> || [[Over]]<br />
|-<br />
| <code>⊸</code> || [[Hook|Before]]/[[Bind]]<br />
|-<br />
| <code>⟜</code> || [[Hook|After]]/[[Bind]]<br />
|-<br />
| <code>⌾</code> || [[Under]]<br />
|-<br />
| <code>⊘</code> || Valences<br />
|-<br />
| <code>◶</code> || Choose<br />
|-<br />
| <code>⎉</code> || [[Rank (operator)|Rank]]<br />
|-<br />
| <code>⚇</code> || [[Depth (operator)|Depth]]<br />
|-<br />
| <code>⍟</code> || [[Power (operator)|Repeat]]<br />
|}<br />
|}<br />
Some modifiers are closely related, and some of their glyphs are intended to allude to this:<br />
* The three 1-modifers Cells (<code>𝔽˘</code>), Each (<code>𝔽¨</code>), and Undo (<code>𝔽⁼</code>) are equivalent to using a right-[[operand]] of <code>¯1</code> with the 2-modifiers Rank (<code>𝔽⎉¯1</code>), Depth (<code>𝔽⚇¯1</code>), and Repeat (<code>𝔽⍟¯1</code>). Therefore the 2-modifiers are circled versions of the 1-modifiers (except in the case of Undo/Repeat).<br />
* Under (<code>𝔽⌾𝔾</code>) is in principle equivalent to <code>𝔾⁼∘𝔽○𝔾</code>. Therefore, <code>⌾</code> is a combination of the glyphs <code>∘</code> and <code>○</code>.<br />
<br />
== The Name BQN ==<br />
<br />
The name "BQN" was originated as a forward iteration of the letters of APL, and [https://mlochbaum.github.io/BQN/#what-kind-of-name-is-bqn "happens to match the capitals in 'Big Questions Notation'"].<br />
<br />
[[Marshall Lochbaum]] [https://chat.stackexchange.com/transcript/message/54753804#54753804 recounts], "I obtained 'BQN' by moving each letter in 'APL' forward by one in the alphabet. I'd come up with the backronym 'Big Questions Notation' by the time I realized N doesn't come after L." Marshall commented further on this in [https://www.arraycast.com/episode-7-transcript Episode 7 of the Array Cast], in response to a question starting at the 11:29 mark.<br />
<br />
== References ==<br />
<references /><br />
<br />
{{APL dialects}}[[Category:BQN| ]][[Category:Array languages]][[Category:Based array languages]][[Category:IR compilers]][[Category:Leading axis languages]][[Category:Languages with tacit programming]]</div>SteveAllen0112https://aplwiki.com/index.php?title=Advent_of_Code&diff=8343Advent of Code2022-04-13T09:06:24Z<p>SteveAllen0112: /* Individuals' solutions */</p>
<hr />
<div>[[File:Advent Of Code Logo.png|thumb|right|Advent Of Code Logo]]<br />
'''[https://adventofcode.com/ Advent of Code]''' ('''AoC''') is an [[wikipedia:Advent calendar|Advent calendar]] of small programming puzzles for a variety of skill sets and skill levels that can be solved in any programming language. This page catalogues efforts by users to solve these puzzles in APL. Feel free to [{{fullurl:{{FULLPAGENAME}}|action=edit&section=1}} add more], including your own.<br />
<br />
The solutions can be used as references for solving the puzzles, or just a general way to hone your APL skills.<br />
<br />
=== Individuals' solutions ===<br />
{| class=wikitable<br />
! Author !! 2015 !! 2016 !! 2017 !! 2018 !! 2019 !! 2020 !! 2021<br />
|-<br />
| adregan: || || || || || || || [https://git.sr.ht/~adregan/advent-of-code-2021 code]<br />
|-<br />
| C. Quilley: || || || || || || [https://github.com/icendoan/aoc/tree/main/2020 code] ||<br />
|-<br />
| Conor Hoekstra: || || || || || || colspan=2 | [https://www.youtube.com/playlist?list=PLVFrD1dmDdvfejkfvQEI2bNfVlNO4iGkK videos]<br />
|-<br />
| Isaac Wooden: || || || [https://github.com/voidhawk42/AoC-APL/tree/main/2017 code] || [https://github.com/voidhawk42/aoc2018 code] || [https://github.com/voidhawk42/aoc2019apl code]<br>[https://www.youtube.com/playlist?list=PLxsf0ccJnXjRx5ap6X5Ludv46HTL2bBzy videos] || [https://github.com/voidhawk42/AoC-APL/tree/main/2020 code] || [https://www.youtube.com/watch?v=7DpoluSQdBo video]<br />
|-<br />
| Jack Franklin: || || || || || || || [https://github.com/jhfranklin/advent-of-code/tree/main/src/2021 code]<br />
|-<br />
| Jon Mikoš: || || || || || || || [https://github.com/MikosJon/AdventOfCode2021 code]<br />
|-<br />
| Lavender: || || || || || || [https://github.com/lvdr/aoc2020 code] ||<br />
|-<br />
| Matthew Maycock: || || || || || [https://github.com/ummaycoc/aoc-2019.apl code] || ||<br />
|-<br />
| Mihaly Barasz || || || || || || || [https://gist.github.com/klao/b37b9a8f28c8235972ce94e8d6cc9f0e code]<br />
|-<br />
| Patrick Ocana Bruno: || || || || || || || [https://github.com/patrickvob/adventofcode/tree/main/2021 code]<br />
|-<br />
| Rory Kemp: || [https://github.com/rak1507/Advent-Of-Code-APL/tree/main/2015 code] || || || || || [https://github.com/rak1507/Advent-Of-Code-APL/tree/main/2020 code] || [https://github.com/rak1507/Advent-Of-Code-APL/tree/main/2021 code]<br />
|-<br />
| schatzmeister: || || || || || || [https://github.com/schatzmeister/adventofcode code] ||<br />
|-<br />
| Woosuk Kwak: || [https://github.com/Bubbler-4/advent-of-apl/tree/master/AoC2015/APLSource code] || || || || || ||<br />
|-<br />
| [https://aplwiki.com/wiki/User:RichPark Rich Park]: || || || || || || || [https://github.com/rikedyp/Advent-of-Code code]<br />
|-<br />
| [https://github.com/pitr pitr] || || || || || || || [https://github.com/pitr/aoc/tree/main/2021 code]<br />
|-<br />
| [[Jay Foad]]: || || || [https://github.com/jayfoad/aoc2017apl code] || [https://github.com/jayfoad/aoc2018apl code] || [https://github.com/jayfoad/aoc2019apl code] || [https://github.com/jayfoad/aoc2020apl code] || [https://github.com/jayfoad/aoc2021apl code]<br />
|-<br />
| [[Nick Nickolov]]: || || || || || || [https://git.sr.ht/~ngn/a/tree code] ||<br />
|-<br />
| [[User:Razetime|Raghu Ranganathan]]: || || || || || || [https://github.com/razetime/AOC2020-APL code] ||<br />
|-<br />
| [[User:Xpqz|Stefan Kruger]]: || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202015%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202016%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202017%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202018%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202019%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202020%20Dyalog%20APL.ipynb notebook] || [https://gist.github.com/xpqz/d406eb493fd2a875ae463cce009463af code]<br />
|-<br />
| [https://github.com/steveAllen0112 Steve Allen]: || || || || || || || [https://github.com/steveAllen0112/Advent_of_Code/tree/main/2021/APL code]<br />
|}<br />
[[category:lists]][[Category:Online resources]]{{APL community}}</div>SteveAllen0112https://aplwiki.com/index.php?title=Advent_of_Code&diff=8342Advent of Code2022-04-13T09:04:57Z<p>SteveAllen0112: /* Individuals' solutions */</p>
<hr />
<div>[[File:Advent Of Code Logo.png|thumb|right|Advent Of Code Logo]]<br />
'''[https://adventofcode.com/ Advent of Code]''' ('''AoC''') is an [[wikipedia:Advent calendar|Advent calendar]] of small programming puzzles for a variety of skill sets and skill levels that can be solved in any programming language. This page catalogues efforts by users to solve these puzzles in APL. Feel free to [{{fullurl:{{FULLPAGENAME}}|action=edit&section=1}} add more], including your own.<br />
<br />
The solutions can be used as references for solving the puzzles, or just a general way to hone your APL skills.<br />
<br />
=== Individuals' solutions ===<br />
{| class=wikitable<br />
! Author !! 2015 !! 2016 !! 2017 !! 2018 !! 2019 !! 2020 !! 2021<br />
|-<br />
| adregan: || || || || || || || [https://git.sr.ht/~adregan/advent-of-code-2021 code]<br />
|-<br />
| C. Quilley: || || || || || || [https://github.com/icendoan/aoc/tree/main/2020 code] ||<br />
|-<br />
| Conor Hoekstra: || || || || || || colspan=2 | [https://www.youtube.com/playlist?list=PLVFrD1dmDdvfejkfvQEI2bNfVlNO4iGkK videos]<br />
|-<br />
| Isaac Wooden: || || || [https://github.com/voidhawk42/AoC-APL/tree/main/2017 code] || [https://github.com/voidhawk42/aoc2018 code] || [https://github.com/voidhawk42/aoc2019apl code]<br>[https://www.youtube.com/playlist?list=PLxsf0ccJnXjRx5ap6X5Ludv46HTL2bBzy videos] || [https://github.com/voidhawk42/AoC-APL/tree/main/2020 code] || [https://www.youtube.com/watch?v=7DpoluSQdBo video]<br />
|-<br />
| Jack Franklin: || || || || || || || [https://github.com/jhfranklin/advent-of-code/tree/main/src/2021 code]<br />
|-<br />
| Jon Mikoš: || || || || || || || [https://github.com/MikosJon/AdventOfCode2021 code]<br />
|-<br />
| Lavender: || || || || || || [https://github.com/lvdr/aoc2020 code] ||<br />
|-<br />
| Matthew Maycock: || || || || || [https://github.com/ummaycoc/aoc-2019.apl code] || ||<br />
|-<br />
| Mihaly Barasz || || || || || || || [https://gist.github.com/klao/b37b9a8f28c8235972ce94e8d6cc9f0e code]<br />
|-<br />
| Patrick Ocana Bruno: || || || || || || || [https://github.com/patrickvob/adventofcode/tree/main/2021 code]<br />
|-<br />
| Rory Kemp: || [https://github.com/rak1507/Advent-Of-Code-APL/tree/main/2015 code] || || || || || [https://github.com/rak1507/Advent-Of-Code-APL/tree/main/2020 code] || [https://github.com/rak1507/Advent-Of-Code-APL/tree/main/2021 code]<br />
|-<br />
| schatzmeister: || || || || || || [https://github.com/schatzmeister/adventofcode code] ||<br />
|-<br />
| Woosuk Kwak: || [https://github.com/Bubbler-4/advent-of-apl/tree/master/AoC2015/APLSource code] || || || || || ||<br />
|-<br />
| [https://github.com/steveAllen0112 Steve Allen]: || || || || || || || [https://github.com/steveAllen0112/Advent_of_Code/tree/main/2021/APL code]<br />
|-<br />
| [https://aplwiki.com/wiki/User:RichPark Rich Park]: || || || || || || || [https://github.com/rikedyp/Advent-of-Code code]<br />
|-<br />
| [https://github.com/pitr pitr] || || || || || || || [https://github.com/pitr/aoc/tree/main/2021 code]<br />
|-<br />
| [[Jay Foad]]: || || || [https://github.com/jayfoad/aoc2017apl code] || [https://github.com/jayfoad/aoc2018apl code] || [https://github.com/jayfoad/aoc2019apl code] || [https://github.com/jayfoad/aoc2020apl code] || [https://github.com/jayfoad/aoc2021apl code]<br />
|-<br />
| [[Nick Nickolov]]: || || || || || || [https://git.sr.ht/~ngn/a/tree code] ||<br />
|-<br />
| [[User:Razetime|Raghu Ranganathan]]: || || || || || || [https://github.com/razetime/AOC2020-APL code] ||<br />
|-<br />
| [[User:Xpqz|Stefan Kruger]]: || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202015%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202016%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202017%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202018%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202019%20Dyalog%20APL.ipynb notebook] || [https://github.com/xpqz/AoCDyalog/blob/master/Advent%20of%20Code%202020%20Dyalog%20APL.ipynb notebook] || [https://gist.github.com/xpqz/d406eb493fd2a875ae463cce009463af code]<br />
|}<br />
[[category:lists]][[Category:Online resources]]{{APL community}}</div>SteveAllen0112