News

Microsoft's New Programming Language for Excel Now Turing Complete

Microsoft, which calls its Excel spreadsheet a programming language, reports that an effort called LAMBDA to make it even more of a programming language is paying off, recently being deemed Turing complete.

Being Turing complete is the litmus test of a full-fledged programming language, marking the ability to imitate a Turing machine. According to one definition, that means, "A programming language is Turing complete if you can implement any possible algorithm with it."

And that's exactly what LAMBDA can now do.

LAMBDA
[Click on image for larger view.] LAMBDA (source: Microsoft).

"You can now, in principle, write any computation in the Excel formula language," said Microsoft researchers in a Jan. 25 blog post.

To get there, researchers at the Calc Intelligence project addressed two shortcomings to the LAMBDA project, which is conducted in coordination with the Excel team and which was first announced early last month. They are:

  • The Excel formula language supported only scalar values like numbers, strings and Booleans
  • It didn't let users define new functions

While researchers were at first skeptical that LAMBDA could be of interest to programming language enthusiasts but actually prove to be too hard for everyday users, they say early community response has been encouraging. Users have taken LAMBDA and applied it to various use cases, some of which were never even envisioned by the team.

"Moreover, even if it takes greater skill and knowledge to author a lambda, it takes no extra skill to call it," researchers said. "LAMBDA allows skilled authors to extend Excel with application-domain-specific functions that appear seamlessly part of Excel to their colleagues, who simply call them.

"It will be interesting to see how users continue to experiment with and apply not only LAMBDA but also data types and dynamic arrays. We believe these new functional programming features will transform how people make decisions with Excel."

LAMBDA in Animated Action
[Click on image for larger, animated GIF view.] LAMBDA in Animated Action (source: Microsoft).

And there is certainly a large audience of both programmers and coders, as Microsoft claims "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."

At this stage, LAMBDA still has some implementation issues to be worked through in future development, which will also see plenty of other enhancements.

"In the short term, we expect to see fully nestable arrays and efficient implementations of array-processing combinators, such as MAP and REDUCE, that take lambda functions as their arguments," researchers said. "Beyond that, we hope to define functions not just by a single formula but by a whole worksheet, so-called sheet-defined functions, or even elastic sheet-defined functions. In practical terms, sheet-defined functions will 'go with the flow' of typical spreadsheet design by allowing users to define a larger function via multiple formulas spread out over multiple cells."

The lengthy Jan. 25 post goes into great technical detail that might be of interest to math aficionados and programmers. There's also a video that explains more. To actually use it, you have to be a member of the Insiders: Beta program.

Note that LAMBDA isn't the only project out there trying to put more "programming" goodness into the hands of Excel users, who write macros in the Visual Basic for Applications variant of VB using the Visual Basic Editor (VBE). For one such example, we last year reported on the Rubberduck project that seeks to "Bring the VBE into this century!"

About the Author

David Ramel is an editor and writer at Converge 360.

comments powered by Disqus

Featured

  • Cloud-Focused .NET Aspire 9.1 Released

    Along with .NET 10 Preview 1, Microsoft released.NET Aspire 9.1, the latest update to its opinionated, cloud-ready stack for building resilient, observable, and configurable cloud-native applications with .NET.

  • Microsoft Ships First .NET 10 Preview

    Microsoft shipped .NET 10 Preview 1, introducing a raft of improvements and fixes across performance, libraries, and the developer experience.

  • C# Dev Kit Previews .NET Aspire Orchestration

    Microsoft's dev team has been busy updating the C# Dev Kit, a Visual Studio Code extension that enhances the C# development experience by providing tools for managing, debugging, and editing C# projects.

  • Hands On: New VS Code Insiders Build Creates Web Page from Image in Seconds

    New Vision support with GitHub Copilot in the latest Visual Studio Code Insiders build takes a user-supplied mockup image and creates a web page from it in seconds, handling all the HTML and CSS.

  • Naive Bayes Regression Using C#

    Dr. James McCaffrey from Microsoft Research presents a complete end-to-end demonstration of the naive Bayes regression technique, where the goal is to predict a single numeric value. Compared to other machine learning regression techniques, naive Bayes regression is usually less accurate, but is simple, easy to implement and customize, works on both large and small datasets, is highly interpretable, and doesn't require tuning any hyperparameters.

Subscribe on YouTube

Upcoming Training Events