{"id":719287,"date":"2021-01-25T09:35:05","date_gmt":"2021-01-25T17:35:05","guid":{"rendered":"https:\/\/www.microsoft.com\/en-us\/research\/?p=719287"},"modified":"2021-01-26T01:03:55","modified_gmt":"2021-01-26T09:03:55","slug":"lambda-the-ultimatae-excel-worksheet-function","status":"publish","type":"post","link":"https:\/\/www.microsoft.com\/en-us\/research\/blog\/lambda-the-ultimatae-excel-worksheet-function\/","title":{"rendered":"LAMBDA: The ultimate Excel worksheet function"},"content":{"rendered":"\n
\"\"\/<\/figure>\n\n\n\n

Ever since it was released in the 1980s, Microsoft Excel has changed how people organize, analyze, and visualize their data, providing a basis for decision-making for the millions of people who use it each day. It\u2019s also the world\u2019s most widely used programming language<\/em>. Excel formulas are written by an order of magnitude more users than all the C, C++, C#, Java, and Python programmers in the world combined. Despite its success, considered as a programming language<\/em> Excel has fundamental weaknesses. Over the years, two particular shortcomings have stood out: (1) the Excel formula language really only supported scalar values\u2014numbers, strings, and Booleans\u2014and (2) it didn\u2019t let users define new functions.<\/p>\n\n\n\n

Until now.<\/p>\n\n\n\n

The Calc Intelligence (opens in new tab)<\/span><\/a> project at Microsoft Research Cambridge has a long-standing partnership with the Excel team to transform spreadsheet formulas into a full-fledged programming language. The fruits of that partnership are starting to appear in the product itself. At the 2019 ACM SIGPLAN Symposium on Principles of Programming Languages (POPL 2019), we announced two significant developments (opens in new tab)<\/span><\/a>: data types (opens in new tab)<\/span><\/a> take Excel beyond text and numbers and allow cells to contain first-class records, including entities linked to external data, and dynamic arrays (opens in new tab)<\/span><\/a> allow ordinary formulas to compute whole arrays that spill into adjacent cells. These changes are a substantial start on our first challenge: rich, fully-first-class structured data in Excel.<\/p>\n\n\n\n

In December 2020, we announced LAMBDA<\/a>, which allows users to define new functions written in Excel\u2019s own formula language, directly addressing our second challenge. These newly defined functions can call other LAMBDA-defined functions, to arbitrary depth, even recursively. With LAMBDA, Excel has become Turing-complete<\/em>. You can now, in principle, write any <\/em>computation in the Excel formula language. LAMBDA is available to members of the Insiders: Beta program. The initial release has some implementation restrictions that we expect to lift in the future. We discussed LAMBDA and some of our research on spreadsheets in a sponsored video presented at POPL 2021<\/a>.<\/p>\n\n\n\n

\n